From: Christophe Ricard Date: Sat, 6 Jun 2015 11:16:49 +0000 (+0200) Subject: NFC: st21nfcb: Move st21nfcb_nci_remove in ndlc_remove X-Git-Tag: v4.2-rc1~130^2~60^2~19 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=e8b72c205e5e02b6574be1e83c0c8c99335f8288;p=linux.git NFC: st21nfcb: Move st21nfcb_nci_remove in ndlc_remove Removing st21nfcb may need to execute some specific commands before stopping the ndlc state machine. Signed-off-by: Christophe Ricard Signed-off-by: Samuel Ortiz --- diff --git a/drivers/nfc/st21nfcb/ndlc.c b/drivers/nfc/st21nfcb/ndlc.c index 6014b5859465..429cf055d532 100644 --- a/drivers/nfc/st21nfcb/ndlc.c +++ b/drivers/nfc/st21nfcb/ndlc.c @@ -286,6 +286,8 @@ EXPORT_SYMBOL(ndlc_probe); void ndlc_remove(struct llt_ndlc *ndlc) { + st21nfcb_nci_remove(ndlc->ndev); + /* cancel timers */ del_timer_sync(&ndlc->t1_timer); del_timer_sync(&ndlc->t2_timer); @@ -294,7 +296,5 @@ void ndlc_remove(struct llt_ndlc *ndlc) skb_queue_purge(&ndlc->rcv_q); skb_queue_purge(&ndlc->send_q); - - st21nfcb_nci_remove(ndlc->ndev); } EXPORT_SYMBOL(ndlc_remove);