Re: [PARPORT] Bug in parport_pc.c (2.2.x)

From: Tim Waugh (twaugh@redhat.com)
Date: Tue Oct 23 2001 - 05:02:40 EDT

  • Next message: Marcel Wijlaars: "Re: [PARPORT] Bug in parport_pc.c (2.2.x)"

    On Tue, Oct 23, 2001 at 08:40:31AM +0200, Marcel Wijlaars wrote:

    > In the 2.2 kernel series check_region, request_region and other
    > functions like it are declared as functions returning void.
    > In the 2.4 kernel series these functions return a pointer value so that
    > an error can be signaled, if a NULL pointer is returned the check or
    > request failed.

    In 2.2 an error is signalled by int return from check_region.

    > In the parport_pc.c file the parport_pc_probe_port function does a "if (
    > check_region(base,3) ) return NULL;" which I think should be "if (
    > !check_region(base,3) ) return NULL;"

    No, it is correct as it is.

    > If I apply this crude hack to parport_pc.c and modify parport_cs.c so it
    > known there are only 3 parport modes (compared to 5 in the 2.2 kernel
    > series) the pcmcia parport module works just fine

    That indicates a bug further along in the code which is only triggered
    when one of the others modes is thought to be available. Try knocking
    out some of the other mode tests one by one.

    Tim.
    */



    -- To unsubscribe, send mail to: linux-parport-request@torque.net --
    -- with the single word "unsubscribe" in the body of the message. --



    This archive was generated by hypermail 2b29 : Tue Oct 23 2001 - 05:09:03 EDT