what you asked for is not logical. but i can tell you what you can do.
1- get proper router, a linksys i doubt will do. a multilayer switch will be best.
2- make two different networks with /24 subnet. example. 10.0.1.0/24 and 10.0.2.0/24. and use two default gateways for ur end systems. 10.0.1.1, 10.0.2.1. this is seperate network.
3- if you want to make it into one big network, then change to /16 subnet in ur end systems, and make your default gateway for all systems 10.0.1.1.
Your linksys would be sufficient if it supports more than one VLAN. If so, create the VLANs you need and establish inter-VLAN routing as desired…