Changes to common source files; not directly applicable to open-vm-tools
MXUser: Lock tracking causes panic
MXUser locks require a unique serial number so the lock stats code
can proprly differentiate between each lock. We can't depend on the
name to be unique as some locks are created and deleted many times,
reusing their names.
The serial number is also used to avoid ASLR attacks... we can't use
the address of a lock... and even if we did, it's possible for that
address to be reused... MXUser locks are dynamically allocated.
The lock tracking code tracks the number of locks and this is now
causing an issue. Way back when it was thought that seeing what
was deemed a huge number of locks indicated a problem... but today
we think those limits are getting quite small.
Enlarge the serial number space to 64-bits. If we constantly create 1M
locks per second it would take over 500000 years before we would have
a problem like this again.