Messages in this thread | | | From | Logan Gunthorpe <> | Date | Wed, 1 Mar 2017 17:29:27 -0700 | Subject | Re: [PATCH v5 0/4] New Microsemi PCI Switch Management Driver |
| |
On 01/03/17 05:23 PM, Logan Gunthorpe wrote: > Because of how poll works, I don't see how I can just hold a semaphore > inside every fops call like the tpm code does.
On 01/03/17 04:58 PM, Jason Gunthorpe wrote: > Both infiniband and TPM have the 'detach' flavour of unplug where the > user is not forced to close their open cdevs. For simpler cases you > can just wait for all cdevs to close with a simple rwsem, much like > sysfs does already during device_del.
Though, after reading your email again, a hard fence on close sounds like a good idea. Tomorrow I'll post a v6 that uses that approach.
Thanks,
Logan
| |