Probably attempting to clear excess stock
If by "excess stock" you mean unspent money hanging around in consumer's wallets, yes. If you mean some stockpile of iPhones in an Apple warehouse, no. Apple doesn't stockpile inventory and hasn't for over a decade. It's well advertised that Apple only keeps at most a 4 week supply of any given product.
This promotion is for those who don't upgrade until their phone dies, technological advances be damned. Apple would prefer as many users as possible get onto iOS 7 (and iOS 8) friendly h/w with reasonably newish handsets.
In a few months the iPhone 4s will be 4 generations old. No doubt many are still happy using that model and see no need to plunk down $200+ for a new phone if theirs still works. I'm a geek so I don't think that way -- 2 years is enough for me -- but a lot of people don't pee their pants in excitement when the newest iPhone is released. So Apple might want to give them an incentive to bump up.
The promo would also help a fiscal quarter which seems void of any stampede creating products -- I don't consider a minor speed bump a big sales maker.
What level of foolish do you have to be to buy into a soon to be obsolete device that will further be crippled by a forced iOS8 upgrade and virtually bricked in 2015 when iOS9 is forced upon it?
And what level arrogance do you have to have to suggest people who get big discounts on current, but soon-to-be discontinued handsets are fools? We don't even know the term of the promotion so you are way to soon to suggest these people are idiots. Not everyone cares about having the latest and greatest phone just like many here don't care to own a nice watch or suit. But if someone with a 4 or 4S can upgrade to a 5S for dirt cheap and they don't care about the 6, more power to them.
Also, do you really think Apple is going to have a promo to get people with "ancient" iPhones to upgrade only to lock them out of the latest OS again? No, Apple is doing this so these people can stay current. I'd be a big bettor that the 5C and 5S will run iOS 8 and 9 just fine.