You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Running AIX 1.3 in virtualbox you often get hangs with an hdintr message (hd is the stock AT style hard disk controller driver and hdintr is its interrupt handler hook) even on a stock install. Running with ad Adaptec (AHA-154x) SCSI instead, there are still disk hangs of a sort but it doesn't hang the whole system, just whatever process was doing the disk iop.
I always assumed these were something to do with the speed of the disk accesses completing in fast modern processor execution like in a VM -- some kind of timing case possible that the drivers were not designed for because it would not be possible on a period-correct machine. However at least for the AT driver case, virtualbox has an option you can set to put in a mandatory minimum response delay to deal with exactly this kind of problem, and it doesn't fix the hangs.
But that made me wonder about what leaix is doing that might be affecting timing if anything.
I haven't used AIX 1.3 much without leaix since I discovered the ad driver worked with an emulated AHA-154x, so I can't rule out leaix as a factor on the SCSI side through the presence of the hangs without it like we can for hd.
For protecting data structures I'm using the spl* functions blocks interrupt calls from the corresponding interrupt group. This is the same approach that was used in the original driver in netbsd. When only one thing can be in kernel code at once since it's a uniprocessor OS, the only concern is another interrupt jumping us into the interrupt handler, so this is sufficient to provide locking of critical sections. We are using splimp which is the customary one for network interfaces in bsds which should be correct.
I've gone through all the calls to splimp and they are all restoring the previous level with splx in all subsequent code paths as required afaict.
Some of the saved level vars are spl_t, and some are int. Need to double check if that has consequences (where are we even getting spl_t)
There is a commented out spl_t declaration; think if some locking is missing, maybe on a special case.
On a bsd system the config line for the device sets what interrupt group the device it is in which determines when its interrupt handler is enabled, and it automatically sets the interrupt level during those calls. If there is any corresponding setup to do here e.g. in the instal script make sure we are doing it.
The text was updated successfully, but these errors were encountered:
Unlike svr4 and friends, the system priority level for a device interrupt handler isn't configured in config files such as the kaf (keyword attribute files) set up by instal here. It's actually in the code, in the leattach routine which sets up the interrupt handler ->
Running AIX 1.3 in virtualbox you often get hangs with an
hdintr
message (hd
is the stock AT style hard disk controller driver andhdintr
is its interrupt handler hook) even on a stock install. Running withad
Adaptec (AHA-154x) SCSI instead, there are still disk hangs of a sort but it doesn't hang the whole system, just whatever process was doing the disk iop.I always assumed these were something to do with the speed of the disk accesses completing in fast modern processor execution like in a VM -- some kind of timing case possible that the drivers were not designed for because it would not be possible on a period-correct machine. However at least for the AT driver case, virtualbox has an option you can set to put in a mandatory minimum response delay to deal with exactly this kind of problem, and it doesn't fix the hangs.
But that made me wonder about what leaix is doing that might be affecting timing if anything.
I haven't used AIX 1.3 much without leaix since I discovered the
ad
driver worked with an emulated AHA-154x, so I can't rule out leaix as a factor on the SCSI side through the presence of the hangs without it like we can forhd
.For protecting data structures I'm using the
spl
* functions blocks interrupt calls from the corresponding interrupt group. This is the same approach that was used in the original driver in netbsd. When only one thing can be in kernel code at once since it's a uniprocessor OS, the only concern is another interrupt jumping us into the interrupt handler, so this is sufficient to provide locking of critical sections. We are usingsplimp
which is the customary one for network interfaces in bsds which should be correct.splimp
and they are all restoring the previous level withsplx
in all subsequent code paths as required afaict.spl_t
, and some areint
. Need to double check if that has consequences (where are we even gettingspl_t
)spl_t
declaration; think if some locking is missing, maybe on a special case.instal
script make sure we are doing it.The text was updated successfully, but these errors were encountered: