Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp2961040ybc; Mon, 25 Nov 2019 06:56:26 -0800 (PST) X-Google-Smtp-Source: APXvYqz0kOEyD6ylbdCh4jAHhW5cU4o85Sv1ooQF1wFQMU9xEqJzr4Xoew+NMlEqTiMMozjCteUl X-Received: by 2002:a17:906:245b:: with SMTP id a27mr38045496ejb.192.1574693786061; Mon, 25 Nov 2019 06:56:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574693786; cv=none; d=google.com; s=arc-20160816; b=KPbkl0apFoqsK9AxLIzo5/Rs7I9rnwwQlEru1YRgxx3W8dxZqn2xEl02+xGstlusjm 1tiwqHEOkUUtHqoEu/hifITMeSgIXucirxxIQWMtzgidD/aHIo4FK5rQBzRhJAypEyxk Z5R0uHLeA/9fJdNWDXma/IRF5RDQ9f7roPSaYM6pIz6TxDqiDw0x2525m2dOW2Xu8YqY BNVTTi1Rp8qAM1UKj1lhwSOyK2tt8mqeeiWHB1rZ4T7MXdiWaY70xAk4YOO1TVqfUBPi elPil23VuPs6znreG8u4ixeL4Pgl5iU6fbVrwsQupyRC1270qxU5Kjwh6xJ5tN6DMdEc EyqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=VbURqT/hIwISYpnd7Ewfv41kiT2pdXc627ZF5Jq5I3E=; b=mOGAc0oi/VGeGstG/rg8UCkEOiuo0j+I+fQ4M9bIB64ZNvEsD5NuvH0N+83Ylsf9Yw xC+P6y3gGWdoDg3rxwtejsNV9ADWr65EmicHrDsioAa3nPRl+G39EsHXA1y5H7nju0R5 cgk1bHiXa3RsjaogPmv2cL9LNTHFQ2nC4Kv4homwTIRlm5xSORulSyVw18RHcnjorWK9 kKdlOtKhCta0VKqUiJs0dGuWiO90Pr3rCVI0HrX2FITP5mjAWKZlmy/7tpqZ1b48WAn5 jpM/JXfE1D9/lCrjmsXkQiTOJmFBkq2BltCAh7eliFFjITZVg/nqzX9qsdeWhhJ2XWxl Umtw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="Jdw2j/a/"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o24si5096454edc.342.2019.11.25.06.56.01; Mon, 25 Nov 2019 06:56:26 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="Jdw2j/a/"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728324AbfKYOy6 (ORCPT + 99 others); Mon, 25 Nov 2019 09:54:58 -0500 Received: from mail-pj1-f67.google.com ([209.85.216.67]:44701 "EHLO mail-pj1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728196AbfKYOy6 (ORCPT ); Mon, 25 Nov 2019 09:54:58 -0500 Received: by mail-pj1-f67.google.com with SMTP id w8so6703744pjh.11; Mon, 25 Nov 2019 06:54:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=VbURqT/hIwISYpnd7Ewfv41kiT2pdXc627ZF5Jq5I3E=; b=Jdw2j/a/FE7gm5TNDBAcYPcU6FC63DMfZkzIU2VewEVpDhpApGP68i6gMhmkchbj+e l9S/ObcbNdRRWkz9zjXvcjpumCg6Q+s3ovDV3hdAD5ukAQxUKFE+DBqMouqqmV7//JRS u70bH5VOM6X/FhPHXVK2DsOfN846AeJlhlwzqTeQZqnqg+P6MuUbZwfXf6E8R60XlV1k jaWMBGsRfvyi9WXECVjImiUV49x/EQJDfz9AYf173Dhl3+k5aWRW4hNsoR2GMOEWWZ8T urn0QqrPGKG56T2cNiQT8AM2lGT/Gm+UU0LG8csbNgsuXMFrtC5MMEO75bNyoGbtFqRj qq+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=VbURqT/hIwISYpnd7Ewfv41kiT2pdXc627ZF5Jq5I3E=; b=b2nT1OAdwBRDrkcyh8nV2g5U7D0uEL1/KWU+cFL8aOT1Vc4UmOxj7jWDFubEOs07eH P2lS+tkb39ZwoiPryjDe2uHkWIgNAHQU2TpmRc5Pdc5Y3BesrOBd/tPy6Wq5bjutik+4 GfiaUdghqRF+cgmK3D2xgTKgDyprn0OuYpPoP1gvdrOB7KFt1kvcyACK2pGs2SvgvaBk 5PsHv4w1e6L/9hpcEamCdUti6BlTzAUjUIm9bO+zYOB1xcZWnCw3JSnq/XDgVgtMBwyu ztzTcaoUsZFmVVDMTgviqeHSz11b2PMm0F1NjueTGILbWDZdcpZEG+fjSR6/KjpdgUti rdlA== X-Gm-Message-State: APjAAAUG3nMKGXbg4qI1xh7ZN+7td6VpVLlMRzK4WvuzFe0FXE9jX2Yd ns7DKQ2AmNfZn17G7ShaI5k= X-Received: by 2002:a17:90a:d155:: with SMTP id t21mr38128482pjw.84.1574693697671; Mon, 25 Nov 2019 06:54:57 -0800 (PST) Received: from debian.net.fpt ([2405:4800:58f7:550c:6dad:1b5f:afc6:7758]) by smtp.gmail.com with ESMTPSA id j4sm8623602pgt.57.2019.11.25.06.54.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Nov 2019 06:54:56 -0800 (PST) From: Phong Tran To: davem@davemloft.net, gregkh@linuxfoundation.org, oneukum@suse.com Cc: alexios.zavras@intel.com, johan@kernel.org, allison@lohutok.net, tglx@linutronix.de, benquike@gmail.com, linux-usb@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Phong Tran Subject: [PATCH 1/2] drivers: net: hso: Fix -Wcast-function-type Date: Mon, 25 Nov 2019 21:54:42 +0700 Message-Id: <20191125145443.29052-1-tranmanphong@gmail.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org correct usage prototype of callback in tasklet_init(). Report by https://github.com/KSPP/linux/issues/20 Signed-off-by: Phong Tran --- drivers/net/usb/hso.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c index 74849da031fa..ca827802f291 100644 --- a/drivers/net/usb/hso.c +++ b/drivers/net/usb/hso.c @@ -1214,8 +1214,9 @@ static void hso_std_serial_read_bulk_callback(struct urb *urb) * This needs to be a tasklet otherwise we will * end up recursively calling this function. */ -static void hso_unthrottle_tasklet(struct hso_serial *serial) +static void hso_unthrottle_tasklet(unsigned long data) { + struct hso_serial *serial = (struct hso_serial *)data; unsigned long flags; spin_lock_irqsave(&serial->serial_lock, flags); @@ -1265,7 +1266,7 @@ static int hso_serial_open(struct tty_struct *tty, struct file *filp) /* Force default termio settings */ _hso_serial_set_termios(tty, NULL); tasklet_init(&serial->unthrottle_tasklet, - (void (*)(unsigned long))hso_unthrottle_tasklet, + hso_unthrottle_tasklet, (unsigned long)serial); result = hso_start_serial_device(serial->parent, GFP_KERNEL); if (result) { -- 2.20.1