summaryrefslogtreecommitdiff
path: root/sound/soc/sof/loader.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/sof/loader.c')
-rw-r--r--sound/soc/sof/loader.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/sof/loader.c b/sound/soc/sof/loader.c
index 4a5b57ecf359..eed3d1e65685 100644
--- a/sound/soc/sof/loader.c
+++ b/sound/soc/sof/loader.c
@@ -385,7 +385,7 @@ static int check_header(struct snd_sof_dev *sdev, const struct firmware *fw,
struct snd_sof_fw_header *header;
size_t fw_size = fw->size - fw_offset;
- if (fw->size < fw_offset) {
+ if (fw->size <= fw_offset) {
dev_err(sdev->dev, "error: firmware size must be greater than firmware offset\n");
return -EINVAL;
}