The switched FE ports wont do sub-interfaces. As they are switch ports you will have to use an SVI for VLAN access, e.g.
interface Vlan10
ip address x.x.x.x y.y.y.y
!
interface FastEthernet4
switchport mode access
switchport access vlan 10
!
interface FastEthernet2
switchport mode trunk
switchport trunk allow 10
!
versus
interface FastEthernet0.10
encapsulation dot1q 10
ip address x.x.x.x y.y.y.y
!