Skip to content

Commit

Permalink
mmc: vub300: fix an error code
Browse files Browse the repository at this point in the history
commit b44f9da upstream.

This error path should return -EINVAL instead of success.

Fixes: 88095e7 ("mmc: Add new VUB300 USB-to-SD/SDIO/MMC driver")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/0769d30c-ad80-421b-bf5d-7d6f5d85604e@moroto.mountain
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Dan Carpenter authored and gregkh committed Nov 28, 2023
1 parent 8387c94 commit 4542aa7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/mmc/host/vub300.c
Original file line number Diff line number Diff line change
Expand Up @@ -2311,6 +2311,7 @@ static int vub300_probe(struct usb_interface *interface,
vub300->read_only =
(0x0010 & vub300->system_port_status.port_flags) ? 1 : 0;
} else {
retval = -EINVAL;
goto error5;
}
usb_set_intfdata(interface, vub300);
Expand Down

0 comments on commit 4542aa7

Please sign in to comment.