On Thursday 18 April 2013, Gilles Chanteperdrix wrote: > On 04/18/2013 06:38 PM, Ross Williamson wrote: > > Is this a bad idea from a RTlinux point of view or a style point of > > view? > > It is a bad idea from a very general point of view. gpiolib does two > things: - it ensures that no two drivers try and request the same > gpio - if toggling a gpio state implies a read-modify-write > operation, it protects it with a spinlock, so that no two drivers can > interrupt each other and cause issues in the operation.
- Code portability. As the underlying hardware evolves or you switch to a different board, your code requires little, if any modification. > By accessing the registers directly, you do not get these > protections. _______________________________________________ Xenomai mailing list [email protected] http://www.xenomai.org/mailman/listinfo/xenomai
