Re: RFC: add udev support to parport_pc



Thank you for the reply.  Comments inline.

I would prefer to actually see == 0x378 in the code, because the
hexademical number is what you see everywhere else, such as the BIOS POST
and /proc/ioports. This also applies to 0x278 and 0x3BC below.

This is what I wanted but I could not figure out how do it. If you tell me how I will be happy to change it. I tried if (p->base == 0x378) but then class_device_create does not get executed.

> +	{
> +		class_device_create(parallel_class, NULL, MKDEV(6, 0), NULL,
> "lp0");
> +		class_device_create(parallel_class, NULL, MKDEV(99, 0), NULL,
> "parport0");
> +	}

Background info before: Because I burnt my on-board LPT port (applying too
much volts or milliamps), I bought a dual-slot PCI add-in card. This card
provides "parport1" and "parport2" at ports at 0xC800 and 0xC00
(/proc/ioports).

The last experience I have with off board cards was about 5 years ago. The choices for the two parallel ports were 378, 278, or 3BC. I was not aware that you had flexibility now.

There are a number of problems in your code:

1- testing just for 0x378/0x278/0x3BC is not enough

2- parport0 could be 0xC800 (address may vary) if you do not
   have any onboard LPT ports.
    2=> that is why I think you should not reserver "lp0"/"parport0"
        for 0x378.
As I said above I was not aware todays off board parallel ports had more choices. I will see what I can do to fix this. Do you have any suggestions?

Thanks,
Jason


- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/



Relevant Pages

  • Re: HARDWARE: Open-Source-Friendly Graphics Cards -- Viable?
    ... If it has any chance of being on-par or a little ... I wouldn't buy a card that wouldn't have the three aforementioned features. ... a blurry fast one. ... send the line "unsubscribe linux-kernel" in ...
    (Linux-Kernel)
  • Re: 2.6.11 vs DVB cx88 stuffs
    ... >> be a good idea to build the cx88 stuff in the DVB section ... the card is working in ntsc just fine. ... Copyright 2005 by Maurice Eugene Heskett, ... send the line "unsubscribe linux-kernel" in ...
    (Linux-Kernel)
  • Re: [RFC] Small PCI core patch
    ... the binary drivers make absolutely no verification of the ... > command streams passed from userland, you can make the card do whatever ... The resulting bad PR should fix their security holes quick ... send the line "unsubscribe linux-kernel" in ...
    (Linux-Kernel)
  • Re: RFC: add udev support to parport_pc
    ... >> hexademical number is what you see everywhere else, such as the BIOS POST ... > As I said above I was not aware todays off board parallel ports had more ... I have not yet checked the BIOS POST message of the i686 where ... the PCI LPT card is in... ...
    (Linux-Kernel)
  • Re: 2.6.9-rc1-bk11+ and 2.6.9-rc1-mm3,4 r8169: freeze during boot (FIX included)
    ... the crash is not immediate. ... possibly in>32-bit addresses but the card hasn't been told to support ... Turning off high DMA fixes it. ... send the line "unsubscribe linux-kernel" in ...
    (Linux-Kernel)