From 130ef4657962efed3c62b27470d7bafd0a11d927 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Wed, 19 Apr 2017 17:04:47 -0400 Subject: [PATCH] Fix get_network_channel for BMCs that dislike 0xe For channel 0xe, we can skip checking if the channel is active, since, obviously, we are connected to that channel. Since *current* active channel cannot be inactive, assume that is good if seen. Change-Id: I894bd27e6c76bb9ace0959566117ad6a6f8866ad --- pyghmi/ipmi/command.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pyghmi/ipmi/command.py b/pyghmi/ipmi/command.py index 5f43b264..17f1350f 100644 --- a/pyghmi/ipmi/command.py +++ b/pyghmi/ipmi/command.py @@ -841,8 +841,11 @@ class Command(object): try: # Some implementations denote an inactive channel # by refusing to do parameter retrieval - self.xraw_command( - netfn=0xc, command=2, data=(channel, 5, 0, 0)) + if channel != 0xe: + # skip checking if channel is active if we are + # actively using the channel + self.xraw_command( + netfn=0xc, command=2, data=(channel, 5, 0, 0)) # If still here, the channel seems serviceable... # However some implementations may still have # ambiguous channel info, that will need to be