On Thu, Nov 13, 2014 at 03:58:43PM +0800, WANG Chao wrote:
Currently we retrieve all the necessary information of an iSCSI
session
and pass them to 2nd kernel. This is wrong way to go for hardware iscsi,
because dracut has already had its own infrastructure to do bring up any
iscsi device configured in firmware of an HBA (Host Bus Bridge).
This patch will determine if an iscsi session is established by firmware
configured iscsi. If it does, then we don't pass anything down to 2nd
kernel. dracut will handle it.
Signed-off-by: WANG Chao <chaowang(a)redhat.com>
---
dracut-module-setup.sh | 23 ++++++++++++++++++++++-
1 file changed, 22 insertions(+), 1 deletion(-)
diff --git a/dracut-module-setup.sh b/dracut-module-setup.sh
index 780601a..18f2294 100755
--- a/dracut-module-setup.sh
+++ b/dracut-module-setup.sh
@@ -469,7 +469,24 @@ kdump_is_iscsi_ibft_cmdline() {
return 1
}
-# No ibft handling yet.
+# Sanity check if an iscsi session is established by iBFT or firmware
+kdump_is_iscsi_fw() {
+
+ if kdump_is_iscsi_hw_cmdline && kdump_is_iscsi_hw_session $1; then
+ return 0
+ fi
Not sure why are we trying to check cmdline here?
+
+ if kdump_is_iscsi_ibft_cmdline && kdump_is_iscsi_ibft_session $1; then
+ return 0
+ fi
I think we can get rid of ibft functionality for now and introduce it once
we know what to do.
Thanks
Vivek