On Wed, Feb 26, 2020 at 06:36:52PM +0300, Denis Efremov wrote: > > One place in the ARM code used to check if the port was equal to FD_DOR, > > this was changed to testing the register by applying a mask to the port, > > as was already done in the sparc code. > > > > The sparc, m68k and parisc code could now be slightly cleaned up to > > benefit from the macro definitions above instead of the equivalent > > hard-coded values. > > Just to note for future ref: the mask (7) can be introduced as define > during future clean up of these magic constants. I'd rather not add it because if we finish to clean up the internal API, then we can have fd_outb(value, base, reg) and fd_inb(base, reg) where reg is one of FD_* and base the base address. In this context we don't need the mask anymore since the register is placed there verbatim. I do have another earlier patch which did just that, its just that I attacked the problem from the wrong side, resulting in too many changes at once for my taste. But I definitely see how we can finish that job and make everything almost elegant. Willy