freebsd-src/sys/dev/spibus
Ian Lepore 7a4f19151a Enhancements and fixes for the spigen(4) driver...
- Resources used by spigen_mmap_single() are now tracked using
  devfs_set_cdevpriv() rather than in the softc.

- Since resources are now tracked per-open-fd, there is no need to try to
  impose any exclusive-open logic, so flags related to that are removed.

- Flags used to track open status to prevent detach() when the device is
  open are replaced with calls to device_busy()/device_unbusy().  That
  extends the protection up the hierarchy so that the spibus and hardware
  controller drivers also can't be detached while the device is open/in use.

- Arbitrary limits on the maximum size of a transfer are removed, along with
  the sysctl variables that allowed the limits to be changed.  There is just
  no reason to limit the size of a spi transfer to the machine's page size.
  Or to any other arbitrary value, really.

- Most of the locking is removed.  It was mostly protecting access to flags
  and fields in the softc that no longer exist.  The locking that remains is
  just to prevent concurrent calls to device_[un]busy().

- The code was calling malloc() with M_WAITOK while holding a mutex in
  several places.  Since most of the locking is gone, that's fixed.
2018-07-11 17:54:41 +00:00
..
ofw_spibus.c Return BUS_PROBE_DEFAULT, not zero, because this is not the one driver 2018-04-07 18:58:58 +00:00
spi.h spi: Add SPIBUS_PNP_INFO macro 2018-06-14 17:20:47 +00:00
spibus.c Incorporate bus and chip select numbers into spigen(4) cdev names. Rather 2018-06-21 21:16:26 +00:00
spibus_if.m Revert r298268 (Add optional chip_select/deselect methods). 2016-04-19 15:39:46 +00:00
spibusvar.h Generate a spibus_set_[ivarname]() convenience function for each ivar, 2018-04-07 20:34:57 +00:00
spigen.c Enhancements and fixes for the spigen(4) driver... 2018-07-11 17:54:41 +00:00