Call saHpiResourceActiveSet on a Resource which
Hot Swap state is not in Insertion or Extraction
Pending.
Expected return: SA_ERR_HPI_INVALID_REQUEST.
Actual return: unknown error code
Test case piece:
if (report.ResourceCapabilities &
SAHPI_CAPABILITY_MANAGED_HOTSWAP)
{
status = saHpiHotSwapStateGet
(session, report.ResourceId, &State);
if (status != SA_OK)
{
retval = HPI_TEST_NA;
}
else
{
if ((State ==
SAHPI_HS_STATE_INSERTION_PENDING) ||
(State ==
SAHPI_HS_STATE_EXTRACTION_PENDING))
{
// The resource is in a state
which we could
// cancel
retval = HPI_TEST_NA;
}
}
}
else
{
// Not a Hot Swap supported Resource
retval = HPI_TEST_NA;
}
if (retval == HPI_TEST_UNKNOWN)
{
//
// Call saHpiResourceActiveSet on a
Resource which
// Hot Swap state is not in Insertion or
Extraction Pending.
//
status = saHpiResourceActiveSet
(session,report.ResourceId);
if (status !=
SA_ERR_HPI_INVALID_REQUEST)
{
printf(" Function
\"saHpiResourceActiveSet\" works abnormally!\n");
printf(" Succeeding in activating
when not extract or insert pending!\n");
printf(" Return value: %s\n",
get_error_string(status));
retval = HPI_TEST_FAIL;
}
else
{
retval = HPI_TEST_PASS;
}
}
Output:
src/resource_active/saHpiResourceActiveSet_T5:
execution: FAILED: Output: 255
Function "saHpiResourceActiveSet" works
abnormally!
Succeeding in activating when not extract or insert
pending!
Return value: (invalid error code)
Logged In: YES
user_id=118691
Platform langley only supports simplified hot swap.
I fixed this in the OpenIPMI plug-in and it should return:
SA_ERR_HPI_CAPABILITY now.
Logged In: YES
user_id=1152287
not found in 1.9.4
Logged In: YES
user_id=1133239
i fixed allowed hotswap transitions, but i cannot test it.
please retest.
Logged In: YES
user_id=1133239
Wrong fix removed