From: SourceForge.net <no...@so...> - 2011-04-15 00:03:38
|
Bugs item #2948127, was opened at 2010-02-09 01:54 Message generated for change (Settings changed) made by avpak You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=532251&aid=2948127&group_id=71730 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: OpenHPI Daemon >Group: 2.17.0 Status: Open Resolution: None Priority: 5 Private: No Submitted By: Ric White (ricwhite) >Assigned to: Anton Pak (avpak) Summary: saHpiHotSwapStateGet() should check SAHPI_CAPABILITY_FRU Initial Comment: The saHpiHotSwapStateGet() routine in the daemon is checking that SAHPI_CAPABILITY_MANAGED_HOTSWAP is set in the ResourceCapabilities, and will return SA_ERR_HPI_CAPABILITY if it is not set. Instead, it should check that SAHPI_CAPABILITY_FRU is set. This appears to be a change made in the HPI B.03.01 Specification. See section 7.9.13 page 238 for details. The existing code in saHpiHotSwapStateGet() in src/safhpi.c : if (!(res->ResourceCapabilities & SAHPI_CAPABILITY_MANAGED_HOTSWAP)) { oh_release_domain(d); /* Unlock domain */ return SA_ERR_HPI_CAPABILITY; } Should be changed to: if (!(res->ResourceCapabilities & SAHPI_CAPABILITY_FRU)) { oh_release_domain(d); /* Unlock domain */ return SA_ERR_HPI_CAPABILITY; } This may also require changes in plug-ins that were not expecting this ABI to be called unless SAHPI_CAPABILITY_MANAGED_HOTSWAP was set. ---------------------------------------------------------------------- >Comment By: Anton Pak (avpak) Date: 2011-04-15 04:03 Message: OK. Picking this up in 2.17.0 boat. I hope Ric doesn't object if I take this bug. ---------------------------------------------------------------------- Comment By: Fred Battle (fbattle) Date: 2011-04-15 03:33 Message: What should happen if FRU capability is not set? Should it return immediately with no error and act as a no-op ? ---------------------------------------------------------------------- Comment By: Fred Battle (fbattle) Date: 2011-04-15 02:44 Message: Actually, this is a bit more complicated. All of the HotSwap functions are not coded completely correctly. saHpiHotSwapStateGet should only check for FRU capability. But the following functions should be fixed to check for both FRU capability and managed hotswap capability: saHpiHotSwapPolicyCancel saHpiResourceActiveSet saHpiResourceInactiveSet saHpiAutoInsertTimeoutGet saHpiAutoInsertTimeoutSet saHpiAutoExtractTimeoutGet saHpiAutoExtractTimeoutSet saHpiHotSwapActionRequest saHpiHotSwapIndicatorStateGet saHpiHotSwapIndicatorStateSet I cite the SAI-HPI-B.03.02, section 7.9.4 Hot Swap Functions. -Fred ---------------------------------------------------------------------- Comment By: Fred Battle (fbattle) Date: 2011-04-05 21:24 Message: I agree with your assessment and fix. I suggest that any plug-ins that behave differently due to this fix are bugs in the plug-ins and not here in the openhpi service. I believe the next step to resolving this issue is to create a Patch file and submitting it. Are you able / available to get this done? Can I help? -Fred ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=532251&aid=2948127&group_id=71730 |