The historical situation back in the early part of the 1990s had a lot to do with it. At the time BSD unix was 'struggling to be free' and was viewed as the way forward in many circles. Linux did not get a working TCP stack for a couple of years after it came out and the internet was still somewhat rarefied.

UC Berkeley and AT&T were engaged in a lawsuit about the ownership of the BSD code, so the future of the 'free' BSD code base was in question. Ultimately UC Berkely won the suit by being able to show large chunks of BSD code in the SVR4 code base. AT&T was suitably embarassed by this and backed down. The UCB people replaced the last of the infringing code with their own work and could release an AT&T free code base.

About this time Bill and Lynn Jolitz took the BSD code base and ported it to the 386, creating 386BSD and documenting it in a famous series of articles in Dr. Dobb's Journal.

The lawsuit went on for long enough to paralyse the potential BSD community, which could not invest significantly in the code base until the legal uncertainty had cleared.

A 'stable' version of Linux finally came out with a working TCP stack.

Linux was available under the GPL which reduced the incentive to fork it. This and Linux Torvalds' effective benevolent dictatorship worked to keep the kernel development unified.

Several competing forks of BSD grew out of the BSD code base, fragmenting the community.

The relative cohesion of the early Linux kernel development meant that Linux moved forward relatively quickly and ultimately gained the mind share. The entire BSD world stood still while the lawsuit was resolved. Even with lawsuit resolved it still lacked the structural cohesiveness of the Linux kernel development process and split into several forks.

Thus, while BSD was (certainly at that point) more mature and arguably technically superior, Linux got the mindshare - which is pretty much the be-all and end-all of success in any large software market.