Skip to content

Commit 59f0071

Browse files
Samuel Zoutiwai
authored andcommitted
ALSA: sound/ppc: Use bitwise instead of arithmetic operator for flags
Fix the following coccinelle warnings: sound/ppc/pmac.c:729:57-58: WARNING: sum of probable bitmasks, consider | sound/ppc/pmac.c:229:37-38: WARNING: sum of probable bitmasks, consider | Reported-by: Hulk Robot <hulkci@huawei.com> Signed-off-by: Samuel Zou <zou_wei@huawei.com> Link: https://lore.kernel.org/r/1588823647-12480-1-git-send-email-zou_wei@huawei.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
1 parent 79263c3 commit 59f0071

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎sound/ppc/pmac.c‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ static int snd_pmac_pcm_prepare(struct snd_pmac *chip, struct pmac_stream *rec,
226226
offset += rec->period_size;
227227
}
228228
/* make loop */
229-
cp->command = cpu_to_le16(DBDMA_NOP + BR_ALWAYS);
229+
cp->command = cpu_to_le16(DBDMA_NOP | BR_ALWAYS);
230230
cp->cmd_dep = cpu_to_le32(rec->cmd.addr);
231231

232232
snd_pmac_dma_stop(rec);
@@ -726,7 +726,7 @@ void snd_pmac_beep_dma_start(struct snd_pmac *chip, int bytes, unsigned long add
726726
chip->extra_dma.cmds->xfer_status = cpu_to_le16(0);
727727
chip->extra_dma.cmds->cmd_dep = cpu_to_le32(chip->extra_dma.addr);
728728
chip->extra_dma.cmds->phy_addr = cpu_to_le32(addr);
729-
chip->extra_dma.cmds->command = cpu_to_le16(OUTPUT_MORE + BR_ALWAYS);
729+
chip->extra_dma.cmds->command = cpu_to_le16(OUTPUT_MORE | BR_ALWAYS);
730730
out_le32(&chip->awacs->control,
731731
(in_le32(&chip->awacs->control) & ~0x1f00)
732732
| (speed << 8));

0 commit comments

Comments
 (0)