.. | .. |
---|
| 1 | +// SPDX-License-Identifier: ISC |
---|
1 | 2 | /* |
---|
2 | 3 | * Copyright (c) 2010 Broadcom Corporation |
---|
3 | | - * |
---|
4 | | - * Permission to use, copy, modify, and/or distribute this software for any |
---|
5 | | - * purpose with or without fee is hereby granted, provided that the above |
---|
6 | | - * copyright notice and this permission notice appear in all copies. |
---|
7 | | - * |
---|
8 | | - * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES |
---|
9 | | - * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF |
---|
10 | | - * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY |
---|
11 | | - * SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES |
---|
12 | | - * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION |
---|
13 | | - * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN |
---|
14 | | - * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
---|
15 | 4 | */ |
---|
16 | 5 | |
---|
17 | 6 | /******************************************************************************* |
---|
.. | .. |
---|
178 | 167 | *fwerr = 0; |
---|
179 | 168 | ret = brcmf_proto_bcdc_msg(drvr, ifidx, cmd, buf, len, false); |
---|
180 | 169 | if (ret < 0) { |
---|
181 | | - brcmf_err("brcmf_proto_bcdc_msg failed w/status %d\n", |
---|
182 | | - ret); |
---|
| 170 | + bphy_err(drvr, "brcmf_proto_bcdc_msg failed w/status %d\n", |
---|
| 171 | + ret); |
---|
183 | 172 | goto done; |
---|
184 | 173 | } |
---|
185 | 174 | |
---|
.. | .. |
---|
195 | 184 | if ((id < bcdc->reqid) && (++retries < RETRIES)) |
---|
196 | 185 | goto retry; |
---|
197 | 186 | if (id != bcdc->reqid) { |
---|
198 | | - brcmf_err("%s: unexpected request id %d (expected %d)\n", |
---|
199 | | - brcmf_ifname(brcmf_get_ifp(drvr, ifidx)), id, |
---|
200 | | - bcdc->reqid); |
---|
| 187 | + bphy_err(drvr, "%s: unexpected request id %d (expected %d)\n", |
---|
| 188 | + brcmf_ifname(brcmf_get_ifp(drvr, ifidx)), id, |
---|
| 189 | + bcdc->reqid); |
---|
201 | 190 | ret = -EINVAL; |
---|
202 | 191 | goto done; |
---|
203 | 192 | } |
---|
.. | .. |
---|
245 | 234 | id = (flags & BCDC_DCMD_ID_MASK) >> BCDC_DCMD_ID_SHIFT; |
---|
246 | 235 | |
---|
247 | 236 | if (id != bcdc->reqid) { |
---|
248 | | - brcmf_err("%s: unexpected request id %d (expected %d)\n", |
---|
249 | | - brcmf_ifname(brcmf_get_ifp(drvr, ifidx)), id, |
---|
250 | | - bcdc->reqid); |
---|
| 237 | + bphy_err(drvr, "%s: unexpected request id %d (expected %d)\n", |
---|
| 238 | + brcmf_ifname(brcmf_get_ifp(drvr, ifidx)), id, |
---|
| 239 | + bcdc->reqid); |
---|
251 | 240 | ret = -EINVAL; |
---|
252 | 241 | goto done; |
---|
253 | 242 | } |
---|
.. | .. |
---|
312 | 301 | } |
---|
313 | 302 | if (((h->flags & BCDC_FLAG_VER_MASK) >> BCDC_FLAG_VER_SHIFT) != |
---|
314 | 303 | BCDC_PROTO_VER) { |
---|
315 | | - brcmf_err("%s: non-BCDC packet received, flags 0x%x\n", |
---|
316 | | - brcmf_ifname(tmp_if), h->flags); |
---|
| 304 | + bphy_err(drvr, "%s: non-BCDC packet received, flags 0x%x\n", |
---|
| 305 | + brcmf_ifname(tmp_if), h->flags); |
---|
317 | 306 | return -EBADE; |
---|
318 | 307 | } |
---|
319 | 308 | |
---|
.. | .. |
---|
408 | 397 | } |
---|
409 | 398 | |
---|
410 | 399 | static void brcmf_proto_bcdc_rxreorder(struct brcmf_if *ifp, |
---|
411 | | - struct sk_buff *skb) |
---|
| 400 | + struct sk_buff *skb, bool inirq) |
---|
412 | 401 | { |
---|
413 | | - brcmf_fws_rxreorder(ifp, skb); |
---|
| 402 | + brcmf_fws_rxreorder(ifp, skb, inirq); |
---|
414 | 403 | } |
---|
415 | 404 | |
---|
416 | 405 | static void |
---|
.. | .. |
---|
460 | 449 | |
---|
461 | 450 | /* ensure that the msg buf directly follows the cdc msg struct */ |
---|
462 | 451 | if ((unsigned long)(&bcdc->msg + 1) != (unsigned long)bcdc->buf) { |
---|
463 | | - brcmf_err("struct brcmf_proto_bcdc is not correctly defined\n"); |
---|
| 452 | + bphy_err(drvr, "struct brcmf_proto_bcdc is not correctly defined\n"); |
---|
464 | 453 | goto fail; |
---|
465 | 454 | } |
---|
466 | 455 | |
---|
.. | .. |
---|
490 | 479 | return -ENOMEM; |
---|
491 | 480 | } |
---|
492 | 481 | |
---|
493 | | -void brcmf_proto_bcdc_detach_pre_delif(struct brcmf_pub *drvr) |
---|
494 | | -{ |
---|
495 | | - struct brcmf_bcdc *bcdc = drvr->proto->pd; |
---|
496 | | - |
---|
497 | | - brcmf_fws_detach_pre_delif(bcdc->fws); |
---|
498 | | -} |
---|
499 | | - |
---|
500 | | -void brcmf_proto_bcdc_detach_post_delif(struct brcmf_pub *drvr) |
---|
| 482 | +void brcmf_proto_bcdc_detach(struct brcmf_pub *drvr) |
---|
501 | 483 | { |
---|
502 | 484 | struct brcmf_bcdc *bcdc = drvr->proto->pd; |
---|
503 | 485 | |
---|
504 | 486 | drvr->proto->pd = NULL; |
---|
505 | | - brcmf_fws_detach_post_delif(bcdc->fws); |
---|
| 487 | + brcmf_fws_detach(bcdc->fws); |
---|
506 | 488 | kfree(bcdc); |
---|
507 | 489 | } |
---|