[PATCH v2 3/7] ALSA: pcm: oss: Drop redundant nonseekable_open() return check

From: phucduc . bui

Date: Thu Jul 02 2026 - 05:17:07 EST


From: bui duc phuc <phucduc.bui@xxxxxxxxx>

nonseekable_open() always returns 0, so the error check is unnecessary.
Remove the dead error handling path.

Signed-off-by: bui duc phuc <phucduc.bui@xxxxxxxxx>
---
sound/core/oss/pcm_oss.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/sound/core/oss/pcm_oss.c b/sound/core/oss/pcm_oss.c
index 9826d9a0be6d..0d7818eb3e14 100644
--- a/sound/core/oss/pcm_oss.c
+++ b/sound/core/oss/pcm_oss.c
@@ -2495,9 +2495,7 @@ static int snd_pcm_oss_open(struct inode *inode, struct file *file)
int nonblock;
wait_queue_entry_t wait;

- err = nonseekable_open(inode, file);
- if (err < 0)
- return err;
+ nonseekable_open(inode, file);

pcm = snd_lookup_oss_minor_data(iminor(inode),
SNDRV_OSS_DEVICE_TYPE_PCM);
--
2.43.0