History log of /openbsd/sys/dev/pci/mfii.c (Results 1 – 25 of 91)
Revision Date Author Comments
# 0f9891f1 24-May-2024 jsg <jsg@openbsd.org>

remove unneeded includes; ok miod@


# 300f71d4 05-Feb-2024 deraadt <deraadt@openbsd.org>

support newer mfii devices; ok jmatthew


# 4e4f5ce5 06-Jul-2023 visa <visa@openbsd.org>

Use mtx_init() to initialize stack-based mutexes

mtx_init() ensures the mutex' lock_object has static storage duration.
This makes it safe to re-enable WITNESS with stack-based mutexes.

OK bluhm@ m

Use mtx_init() to initialize stack-based mutexes

mtx_init() ensures the mutex' lock_object has static storage duration.
This makes it safe to re-enable WITNESS with stack-based mutexes.

OK bluhm@ miod@

show more ...


# 7bcaece1 25-May-2023 kurt <kurt@openbsd.org>

Disable witness for mutexes created on the stack which allows
the ddb command 'show witness' to succeed without panicking.
Leaving witness enabled on these mutexes saves a pointer to
struct lock_type

Disable witness for mutexes created on the stack which allows
the ddb command 'show witness' to succeed without panicking.
Leaving witness enabled on these mutexes saves a pointer to
struct lock_type on the stack which gets clobbered resulting
in a panic in witness_ddb_display_descendants().

okay miod@

show more ...


# 5858a83f 25-Sep-2022 stsp <stsp@openbsd.org>

Give mfii(4) firmware more time to transition out of UNDEFINED state.

Prevents occasional failure to recover from firmware FAULT state where
the driver gave up too early: mfii0: firmware stuck in st

Give mfii(4) firmware more time to transition out of UNDEFINED state.

Prevents occasional failure to recover from firmware FAULT state where
the driver gave up too early: mfii0: firmware stuck in state 0

ok deraadt@

show more ...


# 45495268 16-Sep-2022 stsp <stsp@openbsd.org>

Make mfii(4) recover from firmware FAULT state on startup.

In case firmware initially comes up in FAULT state, reset the device and
give it one more chance to attach successfully. The Linux megaraid

Make mfii(4) recover from firmware FAULT state on startup.

In case firmware initially comes up in FAULT state, reset the device and
give it one more chance to attach successfully. The Linux megaraid_sas
driver applies the same workaround in this case. There seems to be a bug
in some firmware versions which can trigger this behaviour; see mainline
Linux commit 6431f5d7c6025f8b007af06ea090de308f7e6881

Problem observed by me with mfii(4) attached via KVM PCI-passthrough:
mfii0 at pci0 dev 2 function 0 "Symbios Logic MegaRAID SAS2208" rev 0x05: msi
mfii0: firmware fault

With this workaround in place, attachment succeeds and the device works:
mfii0 at pci0 dev 2 function 0 "Symbios Logic MegaRAID SAS2208" rev 0x05: msi
mfii0: firmware fault; attempting full device reset, this can take some time
mfii0: "RAID Ctrl SAS 6G 1GB (D3116C)", firmware 23.29.0-0019, 1024MB cache

Tested for regressions on bare metal by Hrvoje with two different adapters:
mfii0 at pci1 dev 0 function 0 "Symbios Logic MegaRAID SAS3508" rev 0x01: msi
mfii0: "PERC H740P Mini ", firmware 51.16.0-4076, 8192MB cache
mfii0 at pci4 dev 0 function 0 "Symbios Logic MegaRAID SAS2208" rev 0x05: msi
mfii0: "ServeRAID M5110", firmware 23.34.0-0023, 512MB cache

ok jmatthew@

show more ...


# a454aff3 16-Apr-2022 naddy <naddy@openbsd.org>

constify SCSI adapter entry points

ok krw@


# 8d2c75e4 11-Mar-2022 mpi <mpi@openbsd.org>

Constify struct cfattach.


# 834686d2 15-Dec-2020 dlg <dlg@openbsd.org>

neuter the shutdown hooks for now, they seem to crash the fw on some boards.

grumble grumble


# 664c6166 22-Sep-2020 krw <krw@openbsd.org>

Since dlg@'s 2009 scsi midlayer refactoring the 'struct scsi_generic *cmd'
member of 'struct scsi_xfer' has always been pointed at the 'struct scsi_generic
cmdstore' member of the same instance. So n

Since dlg@'s 2009 scsi midlayer refactoring the 'struct scsi_generic *cmd'
member of 'struct scsi_xfer' has always been pointed at the 'struct scsi_generic
cmdstore' member of the same instance. So nuke 'cmdstore' and remove the '*'
from cmd. Take the address of cmd as required by the various casts.

No intentional functional change.

luna88k test by aoyama@, sparc64 test by jmatthew@

Identification of 2009's last *cmd use and ok jmatthew@

show more ...


# eccd596d 01-Sep-2020 krw <krw@openbsd.org>

Rename [READ|WRITE]_BIG to [READ|WRITE]_10. Rename struct scsi_rw_big to
struct scsi_rw_10.

ok gnezdo@ jmatthew@ (who also did sparc64 compile test)


# 7380a3a4 22-Jul-2020 krw <krw@openbsd.org>

Nuke unused struct scsi_link members of adapter softc's where the
driver successfully compiles on one or more of amd64, i386, hppa.


# e5eae15d 20-Jul-2020 krw <krw@openbsd.org>

Move remaining scsi bus initialization info from "prototype scsi link"
fields to struct scsibus_attach_args. Nuke the struct scsi_link *
(saa_sc_link) in scaibus_attach_args.

Explicitly initialize e

Move remaining scsi bus initialization info from "prototype scsi link"
fields to struct scsibus_attach_args. Nuke the struct scsi_link *
(saa_sc_link) in scaibus_attach_args.

Explicitly initialize each field in scsibus_attach_args variables.

show more ...


# ead808c4 19-Jul-2020 krw <krw@openbsd.org>

Move the adapter related items (luns, adapter, adapter_target,
adapter_buswidth, adapter_softc) from struct scsi_link to struct
scsibus_attach_args.

Additional compile tests by jmatthew@ (sparc64) a

Move the adapter related items (luns, adapter, adapter_target,
adapter_buswidth, adapter_softc) from struct scsi_link to struct
scsibus_attach_args.

Additional compile tests by jmatthew@ (sparc64) and aoyam@ (luna88k).

show more ...


# 0b29cb40 16-Jul-2020 krw <krw@openbsd.org>

Access adapter softc via link->bus->sb_adapter_softc.

In sparc64 autoconf access 'luns' via sb_luns and 'adapter_buswidth'
via sb_adapter_buswidth.

Removes last post-config uses of the copies of bu

Access adapter softc via link->bus->sb_adapter_softc.

In sparc64 autoconf access 'luns' via sb_luns and 'adapter_buswidth'
via sb_adapter_buswidth.

Removes last post-config uses of the copies of bus related
information in scsi_link.

show more ...


# d114bbad 13-Jul-2020 krw <krw@openbsd.org>

Where we have a pointer (sc) to the relevant adapter_softc, use
&sc->sc_dev to get a device pointer rather than using the void *
whence we obtained 'sc'.


# d4769f94 13-Jul-2020 krw <krw@openbsd.org>

Remove some pointless casting of void * when assigning one
(scsi_link.adapter_softc) to a pointer of a particular softc type.


# e803e20a 11-Jul-2020 krw <krw@openbsd.org>

Expunge some Captain Obvious comments, tweak whitespace a bit, move a debug
statement. All to make upcoming diff(s) smaller and easier to read.


# 382c0517 27-Jun-2020 krw <krw@openbsd.org>

Nuke trailing whitespace.


# a7997e14 27-Jun-2020 krw <krw@openbsd.org>

No need to bzero()/memset() 'struct scsibus_attach_args' variables
immediately before initializing the only field in the struct.


# 3209772d 24-Jun-2020 cheloha <cheloha@openbsd.org>

kernel: use gettime(9)/getuptime(9) in lieu of time_second(9)/time_uptime(9)

time_second(9) and time_uptime(9) are widely used in the kernel to
quickly get the system UTC or system uptime as a time_

kernel: use gettime(9)/getuptime(9) in lieu of time_second(9)/time_uptime(9)

time_second(9) and time_uptime(9) are widely used in the kernel to
quickly get the system UTC or system uptime as a time_t. However,
time_t is 64-bit everywhere, so it is not generally safe to use them
on 32-bit platforms: you have a split-read problem if your hardware
cannot perform atomic 64-bit reads.

This patch replaces time_second(9) with gettime(9), a safer successor
interface, throughout the kernel. Similarly, time_uptime(9) is replaced
with getuptime(9).

There is a performance cost on 32-bit platforms in exchange for
eliminating the split-read problem: instead of two register reads you
now have a lockless read loop to pull the values from the timehands.
This is really not *too* bad in the grand scheme of things, but
compared to what we were doing before it is several times slower.

There is no performance cost on 64-bit (__LP64__) platforms.

With input from visa@, dlg@, and tedu@.

Several bugs squashed by visa@.

ok kettenis@

show more ...


# 182e13b7 24-Jun-2020 krw <krw@openbsd.org>

Use SDEV_NO_ADAPTER_TARGET instead of the value that is being
aassigned to adapter_buswidth to indicate the adapter is not a target
on the bus.

ok dlg@ as part of a larger diff.


# 383d7846 24-Jun-2020 krw <krw@openbsd.org>

Use SDEV_NO_ADAPTER_TARGET instead of -1 to indicate
the adapter is not a target on the bus.

ok dlg@ as part of a larger diff.


# cac0897d 21-Mar-2020 krw <krw@openbsd.org>

Simplify some goto'ing that jumps a single line or
does nothing at all.

The first one spotted as CID 1452976.

Reads good to millert@

ok mpi@


# 21ceeee0 05-Feb-2020 krw <krw@openbsd.org>

Nuke unnecessary abstraction 'scsi_minphys()' which just calls
'minphys()'. Just use & check for NULL instead, since 'minphys()' is
always called on the code path ([cd|sd|st]minphys) that calls
physi

Nuke unnecessary abstraction 'scsi_minphys()' which just calls
'minphys()'. Just use & check for NULL instead, since 'minphys()' is
always called on the code path ([cd|sd|st]minphys) that calls
physio().

show more ...


1234