score: Fix _Processor_mask_To_uint32_t()

Correctly calculate the array index and shift value in
_Processor_mask_To_uint32_t().  The bugs had no impact yet since this
function was always called with a zero value for the index in RTEMS.
This commit is contained in:
Sebastian Huber
2022-12-20 15:11:25 +01:00
parent f845b95a16
commit f169b513d2

View File

@@ -353,9 +353,9 @@ static inline uint32_t _Processor_mask_To_uint32_t(
uint32_t index
)
{
long bits = mask->__bits[ __bitset_words( index ) ];
long bits = mask->__bits[ index / _BITSET_BITS ];
return (uint32_t) (bits >> (32 * (index % _BITSET_BITS) / 32));
return (uint32_t) ( bits >> ( 32 * ( ( index % _BITSET_BITS ) / 32 ) ) );
}
/**