Re: [PATCH] USB: isp116x: isa_rom_*() calls should depend on CONFIG_ATARI_ROM_ISA

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Michael,

On Sat, Aug 30, 2014 at 3:25 AM, Michael Schmitz <schmitzmic@xxxxxxxxx> wrote:
that's certainly correct - the EtherNAT version of the USB driver didn't
need the ROM accessors but the version including NetUSBee support does for
sure.

Thanks!

Ack'ed-by: Michael Schmitz <schmitzmic@xxxxxxxxx>

If CONFIG_ATARI_ROM_ISA=n:

drivers/usb/host/isp116x.h: In function ‘isp116x_write_addr’:
drivers/usb/host/isp116x.h:382: error: implicit declaration of function
‘isa_rom_writew_raw’
drivers/usb/host/isp116x.h: In function ‘isp116x_raw_write_data16’:
drivers/usb/host/isp116x.h:394: error: implicit declaration of function
‘isa_rom_writew’
drivers/usb/host/isp116x.h: In function ‘isp116x_read_data16’:
drivers/usb/host/isp116x.h:402: error: implicit declaration of function
‘isa_rom_readw_raw’
drivers/usb/host/isp116x.h: In function ‘isp116x_raw_read_data16’:
drivers/usb/host/isp116x.h:411: error: implicit declaration of function
‘isa_rom_readw’

The isa_rom_*() calls should depend on CONFIG_ATARI_ROM_ISA instead of
on CONFIG_ATARI.

Upon closer look, I think I broke the NetUSBee support if CONFIG_ATARI_ROM_ISA
is not set, as the mapping from isp_*() to low-level I/O accessors is
different.

On NetUSBee with CONFIG_ATARI_ROM_ISA=y, we now have:

#ifdef CONFIG_ATARI_ROM_ISA
#define isp_readw(p)            (__raw_readw((p)))
#define isp_writew(v, p)        (__raw_writew((v), (p)))
#define isp_raw_readw(p)        (readw((p)))
#define isp_raw_writew(v, p)    (writew((v), (p)))
#else
  /* sane hardware */
#define isp_readw               readw
#define isp_writew              writew
#define isp_raw_readw           __raw_readw
#define isp_raw_writew          __raw_writew
#endif

Before my patch, there was an "#ifdef CONFIG_ATARI", so the plain isp_*()
mapped to the raw ops on Atari, but to the plain ones elsewhere, while the
isp_raw_*() mapped to the plain ops on Atari, but the raw ops elsewhere.

The plain ops do byteswapping on m68k. If you change the mapping, perhaps
you can get rid of some of the #ifdefs in drivers/usb/host/isp116x-hcd.c?

P.S. Shall I revert my patch for now?

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe linux-m68k" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Video for Linux]     [Yosemite News]     [Linux S/390]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux