IBM couldn't compete with Dell and other direct to buyer manufacturers - but it wasn't because of IP. It was economic. IBM's sales channel had two extra levels of markup, inventory that would go obsolete in warehouses (and have to be bought back by IBM to keep their resellers and distributors happy), it took 4-6 weeks to go from the manufacturer's loading dock to the customer's desktop. Then there was configuration: Dell and the directs custom made each computer - make it once. You had to get an IBM out of the box, rip out what you didn't want and replace it - make it twice - which added even more to the cost.
You're not wrong that OS contributed to it, but having no IP moat (proprietary hw/sw) was the cherry on top, but not the entire sundae.
IBM could have fixed the IP moat by shipping OS/2 for free, but that still would not have fixed the channel problem. The channel problem made an IBM PC cost 20-30% more than their competitors... regardless of OS.
We are going in circles here, IBM did not want a clone market all, they were not able to prevent Compaq to go forward with their reverse engineering, although they did try first with the failed lawsuit and then with MCA PS/2 motherboards.
My point is that without establishing the beachhead in the consumer market that IBM did, the clones wouldn't have had anything to work off of. I'm sure Compaq and others would've been years behind if they had started from scratch, but I'd actually like to know more about that potential alternative history.
The alternative story is what we are going back today, each OEM sells their vertical integrated experience.
In this alternative universe most likely Amiga, Atari ST and Archimedes would keep existing in some form and most businesses wouldn't have cared about IBM PC or eventually got sooner into some UNIX workstation clone.