Skip to content

Commit e0b9357

Browse files
committed
ppc/xive2: Fix logical / bitwise comparison typo
The comparison as written is always false (perhaps confusingly, because the functions/macros are not really booleans but return 0 or the tested bit value). Change to use logical-and. Resolves: Coverity CID 1593721 Reviewed-by: Cédric Le Goater <[email protected]> Signed-off-by: Nicholas Piggin <[email protected]>
1 parent 3449213 commit e0b9357

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

hw/intc/xive2.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1344,7 +1344,7 @@ static void xive2_router_end_notify(Xive2Router *xrtr, uint8_t end_blk,
13441344
return;
13451345
}
13461346

1347-
if (xive2_end_is_crowd(&end) & !xive2_end_is_ignore(&end)) {
1347+
if (xive2_end_is_crowd(&end) && !xive2_end_is_ignore(&end)) {
13481348
qemu_log_mask(LOG_GUEST_ERROR,
13491349
"XIVE: invalid END, 'crowd' bit requires 'ignore' bit\n");
13501350
return;

0 commit comments

Comments
 (0)