I haven't tested routing only at the mac layer, but you could try something like this:
class nexthop_select {
"src_MAC_1 dst_MAC_1"
"src_MAC_2 dst_MAC_2"
"src_MAC_3 dst_MAC_3"
}
when CLIENT_ACCEPTED {
LINK::nexthop [findclass [LINK::lasthop] $::nexthop_select " "]
}
Note that the class would be added under the datagroups section if being entered in the GUI. Need to be on 9.2 to use these commands apparently. My 9.1.1 system doesn't recognize them. Also note that you might want to do some logging to determine how the lasthop is populated (upper/lowercase,leading zeroes omitted, etc)
Good luck!