Re: New-bus unit wiring via hints..

From: Marcel Moolenaar <xcllnt_at_mac.com>
Date: Sat, 27 Oct 2007 15:04:40 -0700
On Oct 27, 2007, at 2:24 PM, Kevin Oberman wrote:

>> From: Marcel Moolenaar <xcllnt_at_mac.com>
>> Date: Sat, 27 Oct 2007 13:57:25 -0700
>>
>>
>> On Oct 27, 2007, at 12:40 PM, Kevin Oberman wrote:
>>
>>>> I'm not mandating anything. I'm merely pointing out how
>>>> reality has changed and that it's important to adapt,
>>>> adopt and improve...
>>>
>>> "Reality has changed"? Yes, it has, at least a bit, but not to the
>>> point where we want to confuse serial ports.
>>
>> Are you saying that "we" should accept reality's change
>> only for as far as it doesn't confuse "us" ???
>
> Just in case I don't understand the issue, feel free to correct me,  
> but
> it sounds like you are saying that there will not be a clear link
> between the serial port (sio) number and the port marked '1' on most
> systems.  If I am wrong about this, please tell me and I climb back
> under my rock.

That is not what I'm saying. What I'm saying is:
If the firmware tells the OS that the port marked
"1" on the back corresponds to a UART that has a
base I/O port address of 0x2e8, then who are we
to disagree and demand that it should be 0x3f8?

You rightly point out that what it really boils
down to is how devX maps to a port on the back or
front of the machine. This mapping should not
change gratuitously. Device wiring achieves that.

>>> In my case, I am only talking to a data logger and not actually
>>> controlling something, but I should not have to worry about having
>>> a port
>>> name change or finding that _UID1 was no longer the same device if I
>>> move to a new mother board.
>>
>> That's unrealistic. If you change the underlying hardware
>> configuration you cannot expect that it doesn't have some
>> sort of effect on the system. Wiring is about making that
>> effect as small as possible, not about having FreeBSD do
>> its own thing with disregard of the hardware.
>
> If I really change the configuration, then I should expect changes in
> operation. But upgrading to a new system or motherboard where the port
> marked '1' is suddenly not sio0 is not a configuration change, in my
> view.

Why not? You replace a mainboard. You really replaced the
whole computer, because there's no concept of chassis
port numbers in FreeBSD. All we know about the hardware
is what is on the mainboard.

> The new system has, to the typical user's eyes, the same
> configuration.

Yes. this means there's a gap between what the user sees
(the chassis) and what FreeBSD sees (the mainboard). As
long as the mainboard is designed for the chassis, that
gap is mostly non-existent or insignificant and what the
firmware tells the OS is what you see on the back (or
front). Otherwise, all bets are off...

> This gets even worse in some cases. For example, many newer mobos  
> have a
> single serial connector on the back and another available only as a
> header connector on the board. (I have a lot of such systems scattered
> all over the country.) I would be extremely upset if the '1' port,
> configured as the console was to become sio1 and I could not access  
> the
> system from the terminal server.

I can imagine. Not the best way to program a firmware.
Then again, if the mainboard was not designed for the
chassis, and it is actually programmed correctly for
the targeted chassis then the fault is not with the
firmware.

Luckily, chassis makers and mainboard makers tend to
standardize on certain layouts, so this hardly ever
is a problem. But, again, we as OS makers should not
make the mistake of assuming too much. Only then will
we actually play along and end up doing the right
thing. Hints can only do harm in that case, which
basically means that hints can only do harm because
we don't need hints to do the right thing...

-- 
Marcel Moolenaar
marcelm_at_juniper.net
Received on Sat Oct 27 2007 - 20:05:19 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:20 UTC