From patchwork Wed Mar 17 09:11:25 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 403067 Delivered-To: patch@linaro.org Received: by 2002:a02:8562:0:0:0:0:0 with SMTP id g89csp293753jai; Wed, 17 Mar 2021 02:12:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx1JcCbTsOPPvh/afmSKz7idkt3Vd+BkwsTuCLIylWciFHb9INFQjQmgOoJpQxIUXh5rokd X-Received: by 2002:aa7:cb0a:: with SMTP id s10mr40515902edt.36.1615972347221; Wed, 17 Mar 2021 02:12:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1615972347; cv=none; d=google.com; s=arc-20160816; b=CCrGpSKecCTLD2E9LVG7476fYumE5B8G313LRodRSuFYzA98BW/3FUhfXwx9bAp4pA /l9/HerwS4TGLvxx9bXM6kBlcWzBj9VDBZ/sLUdS2txvZsHo/YAY6KLD/1BjuAjbBmV1 QAYvSq4R2V7/Aw48nXTZrNz7l5FcvturT8o63pT8UG/wbk+9YuJuyc0Ian94i+cRgFpK 3ZePQTcRET1uBaIRLMZsw8zqKR07vghG21l11hVx/vlC29RzKyUmqP0RMXUVP5jtm+uT Bg4rUHucrVl56RbB3N1sPQ8ESnnRzdACkPqdDdXqLgT/CZQOjKuKwnhqRZbaS1UtIsnK fHTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=PdNAYGEf3HErZd1qMy9Fio2Q6mTHXUXt55dWtvm2uqs=; b=NY/V2EmMHDsPt0+k74HCdLrYK/wuOlnWLLwuX2sqpJResjhcG2Oqtr3j3px+JF0sYJ MXDciMLTXFms0H5uTGkA/RZl0FYO1dwBgy9+NxbJC1XxLQpkFaVDSH3B39+J4Qz/dQPV cGs06N6s/sICgqicM059UVMRtE+NL7jEj/Lg8UYoG409BPid/gGtYKC2BgzrxvAq9oeE dviFTnCVaq+kty54mkHjbGcP/E0mnaxE05PRRYeWXwRiICrNzj7yDdG7rDdzKrw5VbFj SCRaVHoKCWfPnEVHSG8GJIKN28Jk/cI59XnsYujrApdSh0TfzGei/l3OW/wnZp6PJfaQ hwvw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=KoI4pQgL; spf=pass (google.com: domain of linux-scsi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-scsi-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id lo11si16575875ejb.60.2021.03.17.02.12.27 for ; Wed, 17 Mar 2021 02:12:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-scsi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=KoI4pQgL; spf=pass (google.com: domain of linux-scsi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-scsi-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229914AbhCQJL5 (ORCPT ); Wed, 17 Mar 2021 05:11:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42382 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229847AbhCQJLh (ORCPT ); Wed, 17 Mar 2021 05:11:37 -0400 Received: from mail-wm1-x333.google.com (mail-wm1-x333.google.com [IPv6:2a00:1450:4864:20::333]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6F14BC061763 for ; Wed, 17 Mar 2021 02:11:37 -0700 (PDT) Received: by mail-wm1-x333.google.com with SMTP id r10-20020a05600c35cab029010c946c95easo829872wmq.4 for ; Wed, 17 Mar 2021 02:11:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=PdNAYGEf3HErZd1qMy9Fio2Q6mTHXUXt55dWtvm2uqs=; b=KoI4pQgLlCN8e9y0ULjwArxZGVHgE65tgmu+pIBdoAfjkPAL3ETIwM5PA8C8HqEj5i OmAmH+Cja8knY9rm+oohq/XjrAyFZ+P1xuNAvAvSKdzq5v+J3O8q0+oj5wxMb1/vtC52 b7p4uHR6Ba3P7Kg9KGScByrPQh/Hph7zja8aQvLMGzs5ddXwZ2deqKiHCrOGPd/m/6Fp KfS1/9KbSe9sH7DaL7l64Vsbx0vsrKX01XDy5vT0eHLLwUPGYI/2wRPHxPehm8RF4l5R 15LzwLhmvGUw3qQ+FV7JDEJUhJQnfbupA2HA+ivw8zt4lFm83z45Kdw/nrCliL/iMTX2 6tNA== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=PdNAYGEf3HErZd1qMy9Fio2Q6mTHXUXt55dWtvm2uqs=; b=C23d1RaIP61yomueOz3e6V5og2sp01/u0eBvcKq3mek03PxDMA4bq8/TZhpjhssffS 0wbCkGEP5UqLz5URDjGOEbvU8PyvMalwHrQQxPZIwyqIivxunXB/NaJ39TUgoEcKv2ls ndcsSFgnawiCH02EMung3ycQ5dKR4DiFcvFcLJ7niRQQ8OU2K8gRUQcZpYraKG+YmuMR GGZ6u8/EwACPfJ7P07yakOAVGG7rCRfjvpW2cI6GXI3fXFN1obffZTO5BBeB7YEp9dm+ V6sre4KM23W1dsrS3fZjskseUSvLEwutHMl4UAdiIXuYwlfMQYn0unbFd6XXPRNLEqbf xA9Q== X-Gm-Message-State: AOAM531O1t+tqs2AVR3rHXn611e11LlOZYjr8N5n3FAudm0pXj8NyGqa Dzv+lDl347nZFE4pqtoOSr2s4Q== X-Received: by 2002:a05:600c:3546:: with SMTP id i6mr2682279wmq.104.1615972296229; Wed, 17 Mar 2021 02:11:36 -0700 (PDT) Received: from dell.default ([91.110.221.194]) by smtp.gmail.com with ESMTPSA id s83sm1709279wms.16.2021.03.17.02.11.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Mar 2021 02:11:35 -0700 (PDT) From: Lee Jones To: lee.jones@linaro.org Cc: linux-kernel@vger.kernel.org, GOTO Masanori , YOKOTA Hiroshi , "James E.J. Bottomley" , "Martin K. Petersen" , gotom@debian.org, linux-scsi@vger.kernel.org Subject: [PATCH 8/8] scsi: nsp32: Correct expected types in debug print formatting Date: Wed, 17 Mar 2021 09:11:25 +0000 Message-Id: <20210317091125.2910058-9-lee.jones@linaro.org> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20210317091125.2910058-1-lee.jones@linaro.org> References: <20210317091125.2910058-1-lee.jones@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org Fixes the following W=1 kernel build warning(s): drivers/scsi/nsp32.c: In function ‘nsp32_setup_sg_table’: drivers/scsi/nsp32.c:879:6: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 5 has type ‘unsigned int’ [-Wformat=] drivers/scsi/nsp32.c:280:69: note: in definition of macro ‘nsp32_msg’ drivers/scsi/nsp32.c:879:52: note: format string is defined here drivers/scsi/nsp32.c: In function ‘nsp32_detect’: drivers/scsi/nsp32.c:2719:6: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 5 has type ‘int’ [-Wformat=] drivers/scsi/nsp32.c:280:69: note: in definition of macro ‘nsp32_msg’ drivers/scsi/nsp32.c:2719:22: note: format string is defined here drivers/scsi/nsp32.c:2719:6: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 6 has type ‘int’ [-Wformat=] drivers/scsi/nsp32.c:280:69: note: in definition of macro ‘nsp32_msg’ drivers/scsi/nsp32.c:2719:28: note: format string is defined here drivers/scsi/nsp32.c: In function ‘nsp32_suspend’: drivers/scsi/nsp32.c:3267:23: warning: format ‘%ld’ expects argument of type ‘long int’, but argument 6 has type ‘pm_message_t’ {aka ‘struct pm_message’} [-Wformat=] drivers/scsi/nsp32.c:280:69: note: in definition of macro ‘nsp32_msg’ drivers/scsi/nsp32.c:3267:56: note: format string is defined here Cc: GOTO Masanori Cc: YOKOTA Hiroshi Cc: "James E.J. Bottomley" Cc: "Martin K. Petersen" Cc: gotom@debian.org Cc: linux-scsi@vger.kernel.org Signed-off-by: Lee Jones --- drivers/scsi/nsp32.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) -- 2.27.0 diff --git a/drivers/scsi/nsp32.c b/drivers/scsi/nsp32.c index 54abda4d07c64..134bbd2d8b667 100644 --- a/drivers/scsi/nsp32.c +++ b/drivers/scsi/nsp32.c @@ -876,7 +876,7 @@ static int nsp32_setup_sg_table(struct scsi_cmnd *SCpnt) if (le32_to_cpu(sgt[i].len) > 0x10000) { nsp32_msg(KERN_ERR, - "can't transfer over 64KB at a time, size=0x%lx", le32_to_cpu(sgt[i].len)); + "can't transfer over 64KB at a time, size=0x%x", le32_to_cpu(sgt[i].len)); return FALSE; } nsp32_dbg(NSP32_DEBUG_SGLIST, @@ -2716,7 +2716,7 @@ static int nsp32_detect(struct pci_dev *pdev) res = request_region(host->io_port, host->n_io_port, "nsp32"); if (res == NULL) { nsp32_msg(KERN_ERR, - "I/O region 0x%lx+0x%lx is already used", + "I/O region 0x%x+0x%x is already used", data->BaseAddress, data->NumAddress); goto free_irq; } @@ -3264,7 +3264,8 @@ static int nsp32_suspend(struct pci_dev *pdev, pm_message_t state) { struct Scsi_Host *host = pci_get_drvdata(pdev); - nsp32_msg(KERN_INFO, "pci-suspend: pdev=0x%p, state=%ld, slot=%s, host=0x%p", pdev, state, pci_name(pdev), host); + nsp32_msg(KERN_INFO, "pci-suspend: pdev=0x%p, state.event=%x, slot=%s, host=0x%p", + pdev, state.event, pci_name(pdev), host); pci_save_state (pdev); pci_disable_device (pdev);