forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-05-13 9d77db3c730780c8ef5ccd4b66403ff5675cfe4e
kernel/drivers/net/wireless/marvell/libertas/if_sdio.c
....@@ -1,14 +1,10 @@
1
+// SPDX-License-Identifier: GPL-2.0-or-later
12 /*
23 * linux/drivers/net/wireless/libertas/if_sdio.c
34 *
45 * Copyright 2007-2008 Pierre Ossman
56 *
67 * Inspired by if_cs.c, Copyright 2007 Holger Schurig
7
- *
8
- * This program is free software; you can redistribute it and/or modify
9
- * it under the terms of the GNU General Public License as published by
10
- * the Free Software Foundation; either version 2 of the License, or (at
11
- * your option) any later version.
128 *
139 * This hardware has more or less no CMD53 support, so all registers
1410 * must be accessed using sdio_readb()/sdio_writeb().
....@@ -69,7 +65,7 @@
6965 { SDIO_DEVICE(SDIO_VENDOR_ID_MARVELL,
7066 SDIO_DEVICE_ID_MARVELL_LIBERTAS) },
7167 { SDIO_DEVICE(SDIO_VENDOR_ID_MARVELL,
72
- SDIO_DEVICE_ID_MARVELL_8688WLAN) },
68
+ SDIO_DEVICE_ID_MARVELL_8688_WLAN) },
7369 { /* end: all zeroes */ },
7470 };
7571
....@@ -107,7 +103,7 @@
107103 struct if_sdio_packet {
108104 struct if_sdio_packet *next;
109105 u16 nb;
110
- u8 buffer[0] __attribute__((aligned(4)));
106
+ u8 buffer[] __aligned(4);
111107 };
112108
113109 struct if_sdio_card {
....@@ -1210,8 +1206,8 @@
12101206
12111207
12121208 priv = lbs_add_card(card, &func->dev);
1213
- if (!priv) {
1214
- ret = -ENOMEM;
1209
+ if (IS_ERR(priv)) {
1210
+ ret = PTR_ERR(priv);
12151211 goto free;
12161212 }
12171213