BMAC+ & Full Duplex

5 messages, 2 authors, 2000-05-20 · open the first message on its own page

BMAC+ & Full Duplex

From: Mike Hudson <hidden>
Date: 2000-05-18 21:27:20

Has anyone looked into the problem with a BMAC+ not being able to do
 full-duplex 100baseTX? I currently use BootX scripted in the MacOS,
since this allows me to use Apple's Duplexer tool to set Full-Duplex
100BaseTX.
I'd like to move to yaboot/ybin, since about half the time BootX hangs
when I need to remotely reboot.

I've looked at the BMAC/BMAC+ Driver, and some Darwin Code and
there is a register in the darwin code"

#define kTxFullDuplex   0x0200

But I'm wary to add to the code, seeing that it will probably break
compatiblity with the original BMAC (which can't do 100Mbps).
Also, I'm not sure of this will do the trick if the BMAC+ isn't advertising
 100FD, so therefore somehow one would have to access whatever
circutry handles the autonegotiation (MII layer or actual transceiver?)

FYI, I'm running a B&W G3 450 Server, 128MB, 18GB. All my PCI
slots are full (U2SCSI + two serial port boards), so I'm stuck with the
BMAC+
for my network connectivity.

Also, anyone look at implementing 'server mode' on the macs? This is a
nother reason I still use BootX, I can set server mode in MacOS first
before switching to Linux. (Sever mode is Apple's way of rebooting if A
C power lost, crucial if a UPS is used) I've done some background reasearch
on doing this with the CUDA (Power Chip on Pre-G4 desktops), and I'd love
 to discuss this with someone. Too bad this is a non-persistent software
setting,
on my PC it's nice little BIOS option which I can set and forget.

Mike Hudson


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: BMAC+ & Full Duplex

From: Takashi Oe <hidden>
Date: 2000-05-18 22:14:27

On Thu, 18 May 2000, Mike Hudson wrote:

[...no idea about bmac...]
Also, anyone look at implementing 'server mode' on the macs? This is a
nother reason I still use BootX, I can set server mode in MacOS first
before switching to Linux. (Sever mode is Apple's way of rebooting if A
C power lost, crucial if a UPS is used) I've done some background reasearch
on doing this with the CUDA (Power Chip on Pre-G4 desktops), and I'd love
 to discuss this with someone. Too bad this is a non-persistent software
setting,
on my PC it's nice little BIOS option which I can set and forget.
How does this "server mode" work on Mac OS?  I once wrote a little app to
manipulate "auto power on command" via CUDA, and, if the server mode is
just doing CUDA command every so often so that a machine will reboot
automatically, you might be able to use the app with cron.  Not sure.


Takashi Oe


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: BMAC+ & Full Duplex

From: Mike Hudson <hidden>
Date: 2000-05-18 22:33:15

Takashi,

I think we're talking about the same thing.
"Server mode" is like a modified auto-power on that will
ALWAYS boot the computer. i.e. it will boot whenever AC power is present.

I'm going off the technote at the apple website
(http://developer.apple.com/technotes/tn/tn1079.html) which specified
direct hardware access to the CUDA, can we do this from user-space using
ADB commands?

Here's what I was originally thinking about:

cuda_request(&req, NULL, 2, CUDA_PACKET, CUDA_SVR_MODE,
    CUDA_SVR_MODE_ENA)
called somewhere in the kernel
after
#define CUDA_SVR_MODE 0x13 (from apple technote)
#define CUDA_SVR_MODE_ENA 1
etc..
This could be called numerous ways.

Either way, send over the source code to your little app, Takashi. It would
be
exponentially more elegant than a kernel patch.

Mike Hudson

----- Original Message -----
From: "Takashi Oe" <redacted>
To: "Mike Hudson" <redacted>
Cc: <redacted>
Sent: Thursday, May 18, 2000 6:14 PM
Subject: Re: BMAC+ & Full Duplex
How does this "server mode" work on Mac OS?  I once wrote a little app to
manipulate "auto power on command" via CUDA, and, if the server mode is
just doing CUDA command every so often so that a machine will reboot
automatically, you might be able to use the app with cron.  Not sure.


Takashi Oe

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: BMAC+ & Full Duplex

From: Takashi Oe <hidden>
Date: 2000-05-18 23:09:37

On Thu, 18 May 2000, Mike Hudson wrote:
Takashi,

I think we're talking about the same thing.
"Server mode" is like a modified auto-power on that will
ALWAYS boot the computer. i.e. it will boot whenever AC power is present.

I'm going off the technote at the apple website
(http://developer.apple.com/technotes/tn/tn1079.html) which specified
direct hardware access to the CUDA, can we do this from user-space using
ADB commands?
Surely.  There are a handful of pmac apps which excutes direct ADB/CUDA
commands.
Here's what I was originally thinking about:

cuda_request(&req, NULL, 2, CUDA_PACKET, CUDA_SVR_MODE,
    CUDA_SVR_MODE_ENA)
called somewhere in the kernel
after
#define CUDA_SVR_MODE 0x13 (from apple technote)
#define CUDA_SVR_MODE_ENA 1
etc..
This could be called numerous ways.

Either way, send over the source code to your little app, Takashi. It would
be
exponentially more elegant than a kernel patch.
I've modified what I had so that it will enable/disable the server mode.
See attached or other sources like /sbin/clock.  The little app I
mentioned is using 0xb cuda command for specifying some fixed time to
power up, and it's been available somewhere at
http://ppc.linux.or.jp/~toe/


Takashi Oe

Re: BMAC+ & Full Duplex

From: Mike Hudson <hidden>
Date: 2000-05-20 03:25:10

Strange... the util doesn't seem to work at all. The behaviour specified in
MacOS doesn't change. I've verfied all the code line-by-line and (IMHO) the
correct parameters are passed (from the apple technote). The Cuda interface
works, as I've been able to successfully use Paul Mackerras' clock.c to
read/set the clock using the same /dev/adb interface.

For your reference, here's the complete set of ADB pseudo-commands from the
Darwin Source. Some of these are already in the Linux source, some aren't.
Someone should slap this in cuda.h for posterity.

/*
 * ADB Pseudo Commands
 */

#define ADB_PSEUDOCMD_WARM_START         0x00
...START_STOP_AUTO_POLL   0x01
...GET_6805_ADDRESS       0x02
...GET_REAL_TIME      0x03
GET_PRAM           0x07
SET_6805_ADDRESS       0x08
SET_REAL_TIME      0x09
POWER_DOWN         0x0a
SET_POWER_UPTIME      0x0b
SET_PRAM           0x0c
MONO_STABLE_RESET      0x0d
SEND_DFAC          0x0e
BATTERY_SWAP_SENSE     0x10
RESTART_SYSTEM         0x11
SET_IPL_LEVEL      0x12
FILE_SERVER_FLAG       0x13 ***
SET_AUTO_RATE      0x14
GET_AUTO_RATE      0x16
SET_DEVICE_LIST        0x19
GET_DEVICE_LIST        0x1a
SET_ONE_SECOND_MODE    0x1b
SET_POWER_MESSAGES     0x21
GET_SET_IIC        0x22
ENABLE_DISABLE_WAKEUP  0x23
TIMER_TICKLE       0x24
COMBINED_FORMAT_IIC    0x25


A possible explanation for the failure lies in the fact that the Darwin
source calls File Server mode a flag. From my experience a flag is used to
set a minor parameter on another command, not provide any individual
functionality. Possibly the documented "Server Mode" functionality depends
on another value/command? (I'm guessing)

I have three questions:

1) Has anyone independently verified if this utility works?

2) If the powerup time is already passed, will the Mac boot on restoration
of AC power? This could be used to provide similar functionality to the
server mode flag. I.e. set the wakeup time to the current time on boot.

3) Does anyone have any decent documentation on the Cuda and it's commands,
aside from the Darwin snippet, the technote and the linux/darwin sources
(which seem to focus on the clock and power on/off/restart)?

Thanks,

Mike Hudson


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help