Skip to content

Commit 237fe88

Browse files
ColinIanKingDamien Le Moal
authored andcommitted
ata: pata_ali: remove redundant return statement
A return statement is unnecessarily complicated, currently value in variable mask is bitwise-masked and the variable is being updated and then returned. Just updating the mask is all that is required as the following statement is a return. Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Signed-off-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
1 parent a17ab7a commit 237fe88

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/ata/pata_ali.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ static unsigned long ali_20_filter(struct ata_device *adev, unsigned long mask)
123123
mask &= ~(ATA_MASK_MWDMA | ATA_MASK_UDMA);
124124
ata_id_c_string(adev->id, model_num, ATA_ID_PROD, sizeof(model_num));
125125
if (strstr(model_num, "WDC"))
126-
return mask &= ~ATA_MASK_UDMA;
126+
mask &= ~ATA_MASK_UDMA;
127127
return mask;
128128
}
129129

0 commit comments

Comments
 (0)