From patchwork Sat Apr 30 00:01:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joshua Dickens X-Patchwork-Id: 12833009 X-Patchwork-Delegate: jikos@jikos.cz Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D9C4FC433EF for ; Sat, 30 Apr 2022 00:02:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233919AbiD3AFi (ORCPT ); Fri, 29 Apr 2022 20:05:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47484 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232825AbiD3AFh (ORCPT ); Fri, 29 Apr 2022 20:05:37 -0400 Received: from mail-pg1-x535.google.com (mail-pg1-x535.google.com [IPv6:2607:f8b0:4864:20::535]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 536C26B657 for ; Fri, 29 Apr 2022 17:02:17 -0700 (PDT) Received: by mail-pg1-x535.google.com with SMTP id t13so7605937pgn.8 for ; Fri, 29 Apr 2022 17:02:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joshua-dickens-com.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=figok7DkRFltGyTxP5Nz5BbOx0HgYSqPvBi9D+MhFSE=; b=twIvUfPmsvX+BvGmaw7oQ7lap013Mgvg48Qfi64W8+Gi3FM4yZLoHHMDElJQipNkdO GeGnO0GeLeAGJhPhTX6in6Ltv7XeLbKZJkG/P4MPVqTZcMhTBi2fVw793eCk7tDo2c+Z wQA9kdjUNHa67EvGBBpPl+lcBKfP57DaQ1LjgPrHScKQy77Iwm+CFJB5VKy+TUP+Z4XV ON5QlGN/MMzpixH83Pk8glOO9TxLvDwK88UbSurHwBAqLHh2paHwTlCBJFcbxyMU+b6r jWu9DQJwcN9OpSF8RyePEqcbxU0gSOxGXTl1+kwlVVhInoI84amnZNQErxudGqF8cTT4 SdiA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=figok7DkRFltGyTxP5Nz5BbOx0HgYSqPvBi9D+MhFSE=; b=2xh7SoA1/3X19dJBAyXN178XrxYHNjipOKM9kUVX6XHq09Re4GIq1ni+RUqZ7/QG+w f0SVbFblEVaqYX81tZQ47J8qf0/pGeqTurmA+iLaNIdoCkWxV1R864GxLdvy7DcLdm8v rFAFJyDs7FVpOAhp3jyP5XQXtt8Vp/gdjR28n/Ifrw7BPR7puxon70JD++zdMFsEloUe V9gRB9CFuf3Nr0SRvRPs273CQHVksBppKbIz4Oe/vsUYMuWkLAOmU0tUSwtP7yptXBt/ idJecZHt9G2pCO9kckTBSV2OgJpQ4ht4gSKSfIhm5IJ53zbxXCbYG9m6vsn5/TUUbz4L rY8Q== X-Gm-Message-State: AOAM533P7v2djJJgX29xzQByBTUQSCed+heycRL16fGk6UJUKPtHRTqq 7ElIWRz+ZBABLgFUi6Smy4x71uTlDgxCoOkUKw0= X-Google-Smtp-Source: ABdhPJzl6szC5/QuB9f3+8YC8tz+U39bBtYH0DGa9CmQE8DWpVr1bTCUbJRLO257D0UxNSJvDYXG/Q== X-Received: by 2002:a63:f857:0:b0:3ab:2243:4b1a with SMTP id v23-20020a63f857000000b003ab22434b1amr1278463pgj.163.1651276936661; Fri, 29 Apr 2022 17:02:16 -0700 (PDT) Received: from fedora.. (c-76-27-202-13.hsd1.or.comcast.net. [76.27.202.13]) by smtp.gmail.com with ESMTPSA id h18-20020a170902f71200b0015e8d4eb1bbsm165277plo.5.2022.04.29.17.02.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Apr 2022 17:02:15 -0700 (PDT) From: Joshua Dickens X-Google-Original-From: Joshua Dickens To: linux-input@vger.kernel.org, Jiri Kosina , Benjamin Tissoires Cc: Ping Cheng , Aaron Armstrong Skomra , Jason Gerecke , Joshua-Dickens , kernel test robot , Joshua Dickens Subject: [PATCH] Hid: wacom: Fix kernel test robot warning Date: Fri, 29 Apr 2022 17:01:34 -0700 Message-Id: <20220430000134.608043-1-Joshua@Joshua-Dickens.com> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org From: Joshua-Dickens Kernel test robot throws the following warning - >> drivers/hid/wacom_wac.c:2411:42: warning: format specifies type 'unsigned short' but the argument has type 'int' [-Wformat] hid_warn(hdev, "Dropped %hu packets", value - wacom_wac->hid_data.sequence_number); ~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ %d Explicitly casting the argument to unsigned short to silence the warning and retain the intended behavior. Reported-by: kernel test robot Signed-off-by: Joshua Dickens --- drivers/hid/wacom_wac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/hid/wacom_wac.c b/drivers/hid/wacom_wac.c index 64fe573deb9b..9470c2b0b529 100644 --- a/drivers/hid/wacom_wac.c +++ b/drivers/hid/wacom_wac.c @@ -2408,7 +2408,7 @@ static void wacom_wac_pen_event(struct hid_device *hdev, struct hid_field *field return; case WACOM_HID_WD_SEQUENCENUMBER: if (wacom_wac->hid_data.sequence_number != value) - hid_warn(hdev, "Dropped %hu packets", value - wacom_wac->hid_data.sequence_number); + hid_warn(hdev, "Dropped %hu packets", (unsigned short)(value - wacom_wac->hid_data.sequence_number)); wacom_wac->hid_data.sequence_number = value + 1; return; }