From: Bjorn Andersson Date: Wed, 11 Oct 2017 06:45:17 +0000 (-0700) Subject: net: qrtr: Invoke sk_error_report() after setting sk_err X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=ae85bfa87821b9fa60bf846c09a6a0056d87cdb2;p=linux.git net: qrtr: Invoke sk_error_report() after setting sk_err Rather than manually waking up any context sleeping on the sock to signal an error we should call sk_error_report(). This has the added benefit that in-kernel consumers can override this notification with its own callback. Signed-off-by: Bjorn Andersson Signed-off-by: David S. Miller --- diff --git a/net/qrtr/qrtr.c b/net/qrtr/qrtr.c index c2f5c13550c05..7e4b49a8349e0 100644 --- a/net/qrtr/qrtr.c +++ b/net/qrtr/qrtr.c @@ -541,7 +541,7 @@ static void qrtr_reset_ports(void) sock_hold(&ipc->sk); ipc->sk.sk_err = ENETRESET; - wake_up_interruptible(sk_sleep(&ipc->sk)); + ipc->sk.sk_error_report(&ipc->sk); sock_put(&ipc->sk); } mutex_unlock(&qrtr_port_lock);