ALSA: pci/rme9652/hdspm: remove always true condition

Fix W=1 warning:

sound/pci/rme9652/hdspm.c: In function ‘hdspm_autosync_ref’:
sound/pci/rme9652/hdspm.c:3030:16: warning: comparison of unsigned
expression >= 0 is always true [-Wtype-limits]
 3030 |   if ((syncref >= HDSPM_AES32_AUTOSYNC_FROM_WORD) &&
      |                ^~

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20200702193604.169059-16-pierre-louis.bossart@linux.intel.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
Pierre-Louis Bossart 2020-07-02 14:35:56 -05:00 committed by Takashi Iwai
parent 6cdc01ebdf
commit ab3ee09261
1 changed files with 2 additions and 2 deletions

View File

@ -3027,8 +3027,8 @@ static int hdspm_autosync_ref(struct hdspm *hdspm)
unsigned int status = hdspm_read(hdspm, HDSPM_statusRegister); unsigned int status = hdspm_read(hdspm, HDSPM_statusRegister);
unsigned int syncref = (status >> HDSPM_AES32_syncref_bit) & 0xF; unsigned int syncref = (status >> HDSPM_AES32_syncref_bit) & 0xF;
if ((syncref >= HDSPM_AES32_AUTOSYNC_FROM_WORD) && /* syncref >= HDSPM_AES32_AUTOSYNC_FROM_WORD is always true */
(syncref <= HDSPM_AES32_AUTOSYNC_FROM_SYNC_IN)) { if (syncref <= HDSPM_AES32_AUTOSYNC_FROM_SYNC_IN) {
return syncref; return syncref;
} }
return HDSPM_AES32_AUTOSYNC_FROM_NONE; return HDSPM_AES32_AUTOSYNC_FROM_NONE;