mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-05 16:10:55 +00:00
Use geom disk list
instead camcontrol identify
.
The new way works for almost any disk, while the old only for ATA. MFC after: 2 weeks
This commit is contained in:
parent
c66784839b
commit
cdba914b3f
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=296654
|
@ -82,8 +82,8 @@ do
|
|||
esac
|
||||
fi
|
||||
|
||||
# Try and find some identification information with camcontrol
|
||||
NEWLINE=$(camcontrol identify $DEV 2>/dev/null | sed -ne 's/^device model *//p')
|
||||
# Try and get some identification information from GEOM
|
||||
NEWLINE=$(geom disk list $DEV 2>/dev/null | sed -ne 's/^ descr: *//p')
|
||||
if [ -z "$NEWLINE" ]; then
|
||||
NEWLINE=" <Unknown Device>"
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue