netdev
[Top] [All Lists]

Re: [PATCH] (5/6) ibmtr -- probe2

To: Stephen Hemminger <shemminger@xxxxxxxx>
Subject: Re: [PATCH] (5/6) ibmtr -- probe2
From: Mike_Phillips@xxxxxxxxxxx
Date: Thu, 16 Oct 2003 15:52:50 -0700
Cc: jgarzik@xxxxxxxxx, netdev@xxxxxxxxxxx, netdev-bounce@xxxxxxxxxxx
Sender: netdev-bounce@xxxxxxxxxxx
> typedef struct ibmtr_dev_t {
> +    struct tok_info         ti;         /* must be first! */

Why must this be first ?? Sounds like an alignment issue, we shouldn't
assume some is aligned correctly just because it's the first entry.

>+           if (err)
>+                       goto out1;
>+
>+           return 0;
>+ out1:

Replace with:
            if (!err) return 0;
instead of the extra lines of code.

There also a patch of code at the end that changes stuff from dev_ibmtr[i]
to dev and then sets dev_ibmtr[i] = dev. Is there a really good reason for
this. I can't see any real reason for the change.

A small note for some of the reasoning behind the strangeness of the
probing. T/R ISA devices typically live on port A20, some old legacy system
only have 23 bit, not 24 bit addressing here and an automatic probe on A20
will conflict with anything on 220 (ie soundcard) and lock the machine
solid. Hence the ability to absolutely specify the port to be probed. (The
probing years ago used to be really, really simple, you just probed A20 and
A24 and saw if the card was there)

Mike




<Prev in Thread] Current Thread [Next in Thread>