From: Norbert Preining <norbert@preining.info>
To: linux-kernel@vger.kernel.org
Subject: PCI SATA adapter marks all devices as removable
Date: Sun, 4 Jul 2021 14:19:44 +0900 [thread overview]
Message-ID: <YOFE8BqRVMxU1RbF@bulldog.preining.info> (raw)
Dear all
(please Cc)
(kernel 5.13, Debian/sid)
I recently installed a PCI SATA adapter:
06:00.0 SATA controller: Marvell Technology Group Ltd. 88SE9215 PCIe 2.0 x1 4-port SATA 6 Gb/s Controller (rev 11) (prog-if 01 [AHCI 1.0])
Subsystem: Marvell Technology Group Ltd. 88SE9215 PCIe 2.0 x1 4-port SATA 6 Gb/s Controller
Flags: bus master, fast devsel, latency 0, IRQ 146
I/O ports at c050 [size=8]
I/O ports at c040 [size=4]
I/O ports at c030 [size=8]
I/O ports at c020 [size=4]
I/O ports at c000 [size=32]
Memory at df540000 (32-bit, non-prefetchable) [size=2K]
Expansion ROM at df500000 [disabled] [size=256K]
Capabilities: [40] Power Management version 3
Capabilities: [50] MSI: Enable+ Count=1/1 Maskable- 64bit-
Capabilities: [70] Express Legacy Endpoint, MSI 00
Capabilities: [e0] SATA HBA v0.0
Capabilities: [100] Advanced Error Reporting
Kernel driver in use: ahci
and now disks attached via these sata ports show up as "Removable".
In 2016 (kernel 4.4) this was introduced and some fix was done in git
commit dc8b4afc4a04fac8ee55a19b59f2356a25e7e778
Author: Manuel Lauss <manuel.lauss@gmail.com>
Date: Sat Feb 27 16:10:05 2016 +0100
ata: ahci: don't mark HotPlugCapable Ports as external/removable
diff --git a/drivers/ata/libahci.c b/drivers/ata/libahci.c
index 513b3fa74d78..85ea5142a095 100644
--- a/drivers/ata/libahci.c
+++ b/drivers/ata/libahci.c
@@ -1168,8 +1168,7 @@ static void ahci_port_init(struct device *dev, struct ata_port *ap,
/* mark esata ports */
tmp = readl(port_mmio + PORT_CMD);
- if ((tmp & PORT_CMD_HPCP) ||
- ((tmp & PORT_CMD_ESP) && (hpriv->cap & HOST_CAP_SXS)))
+ if ((tmp & PORT_CMD_ESP) && (hpriv->cap & HOST_CAP_SXS))
ap->pflags |= ATA_PFLAG_EXTERNAL;
}
I also miss the possibility to disable hotplug in the SATA extension
card, so I see now all connected devices as removable devices in DE.
Is this to be expected? Is there a way around this?
(Please Cc)
Thanks
Norbert
--
PREINING Norbert https://www.preining.info
Fujitsu Research + IFMGA Guide + TU Wien + TeX Live + Debian Dev
GPG: 0x860CDC13 fp: F7D8 A928 26E3 16A1 9FA0 ACF0 6CAC A448 860C DC13
reply other threads:[~2021-07-04 5:45 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YOFE8BqRVMxU1RbF@bulldog.preining.info \
--to=norbert@preining.info \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®