Its obviously both. Newly written software should not be optimized to run on completely obsolete hardware...it should be optimized to run on the absolute latest hardware. If were managing that division I wouldn't have it any other way.
It also does not hurt to have people motivated to update their older hardware, because they want a device designed to power the new feature they're after.
Yes, it is planned obsolescence, but its also BETTER for all than the alternative. AKA no innovation, no cutting edge features, no improvements year after year.
I don't give much consideration to people who kick and scream that their obsolete hardware doesn't run the latest software as well as the latest hardware. You'd be kicking and screaming just as much if Apple cut off the iPad 2 from iOS 8. I don't care if your iPad is only 3 years old....thats obsolete in the tech world.
(side note: the only reason iPad 2 is allowed to run iOS 8 is because it remained available for sale as new device up until only a few short months ago. Apple wants to make sure buyers in the last 12 months all receive at least 1 OS upgrade. That said, if you were OK with how iOS 7 ran on iPad 2 (IMO, unusably bad) then you should be fine with it on iOS 8, at there should not be much difference. If it seems like there is, restore it)