From patchwork Tue Jul 24 18:29:01 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Randy Dunlap X-Patchwork-Id: 948743 X-Patchwork-Delegate: boris.brezillon@free-electrons.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="N8SQuyfb"; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=infradead.org header.i=@infradead.org header.b="CCutB7dr"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41Zn2L20dfz9s0w for ; Wed, 25 Jul 2018 04:29:27 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Date:Message-ID:Subject: From:To:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=7tdf3JUUPLhbmfDyQH9USvOyr+T6emxmCxrSxVCXOag=; b=N8SQuyfbZIeG+i Oa2UO1BwZdVqqmOsGpWU2VG/PlGZqf6466sZMl1wDFY95NQxLn7E5lIJateTqJfWNW6bLq+Bf+rWi LrtASsnbUEvWD3eNjWK2CmerjLZACQ6rekaT7b9MrcVoGr6JoxNyfmVxmpowovUMd876pDWA67Uir X5sl3fyZApsGWq+OEEqxq0YIYJyz/B/oiZYRTYb91g6Bd8G/V28hjWRAfKa13hxqE7rBzw4P3n7D0 GnieH8B2gli837vm6jzVAaclZBEcV5rkEcrY+dS1XD3Dwqu3JjTUf3IGHEcuDVammNz6/jEwTMgMR dfjhWJNA8Rs0hyIG8ikQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fi23b-0000xD-SX; Tue, 24 Jul 2018 18:29:11 +0000 Received: from merlin.infradead.org ([2001:8b0:10b:1231::1]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fi23Z-0000x4-Sd for linux-mtd@bombadil.infradead.org; Tue, 24 Jul 2018 18:29:09 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Transfer-Encoding:Content-Type: MIME-Version:Date:Message-ID:Subject:From:Cc:To:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=dcyFEVVOU7+x6eQ6PtkIB6x08xZuSB3oCDlIX9RfMz0=; b=CCutB7drRffoY/2lZuZbLvyFbt tiBliCcqd+LR8EG+oTWxzkAGKo8LZxhtQXmMJItQzVm5vcUNEupGmdI+kiQEEyz6Ur63IB4qPQqty Qen8TVrbzW1UwdbudR6jWI3iF69+Wp3bJ1b/L0+0W+SxTNLUQhs1T5K3RQIozap4xDJNvsnDCDYIb uSE/H5E3VDf7yb0L+J0g6/0uJbQnhJzyOy91h3PEkoW5FuWGTdGn47U4+bT7M8TMJR7aD1AwDJhXQ 1xVBGMPn6ZQ3rY85Di7Cm1qWJx3t3W7IgQ9hxLdbDUmyi6s0OnDGQnVxgKbxR9bRjpTknmxE4L0gt d9a7eGpw==; Received: from static-50-53-52-16.bvtn.or.frontiernet.net ([50.53.52.16] helo=midway.dunlab) by merlin.infradead.org with esmtpsa (Exim 4.90_1 #2 (Red Hat Linux)) id 1fi23T-0003H0-2w; Tue, 24 Jul 2018 18:29:03 +0000 To: LKML , linux-sh@vger.kernel.org, linux-mtd@lists.infradead.org From: Randy Dunlap Subject: [PATCH v3] mtd/maps: fix solutionengine.c printk format warnings Message-ID: <578dd079-80d0-939a-fbfd-ae101da1dc29@infradead.org> Date: Tue, 24 Jul 2018 11:29:01 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 Content-Language: en-US X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Rich Felker , Sergei Shtylyov , Yoshinori Sato , Marek Vasut , Richard Weinberger , Boris Brezillon , Brian Norris , David Woodhouse Sender: "linux-mtd" Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org From: Randy Dunlap Fix 2 printk format warnings (this driver is currently only used by arch/sh/) by using "%pap" instead of "%lx". Fixes these build warnings: ../drivers/mtd/maps/solutionengine.c: In function 'init_soleng_maps': ../include/linux/kern_levels.h:5:18: warning: format '%lx' expects argument of type 'long unsigned int', but argument 2 has type 'resource_size_t' {aka 'unsigned int'} [-Wformat=] ../drivers/mtd/maps/solutionengine.c:62:54: note: format string is defined here printk(KERN_NOTICE "Solution Engine: Flash at 0x%08lx, EPROM at 0x%08lx\n", ~~~~^ %08x ../include/linux/kern_levels.h:5:18: warning: format '%lx' expects argument of type 'long unsigned int', but argument 3 has type 'resource_size_t' {aka 'unsigned int'} [-Wformat=] ../drivers/mtd/maps/solutionengine.c:62:72: note: format string is defined here printk(KERN_NOTICE "Solution Engine: Flash at 0x%08lx, EPROM at 0x%08lx\n", ~~~~^ %08x Cc: David Woodhouse Cc: Brian Norris Cc: Boris Brezillon Cc: Marek Vasut Cc: Richard Weinberger Cc: linux-mtd@lists.infradead.org Cc: Yoshinori Sato Cc: Rich Felker Cc: linux-sh@vger.kernel.org Cc: Sergei Shtylyov Signed-off-by: Randy Dunlap --- v3: drop anding the phys addresses with 0x1fffffff since the only phys addresses are 0 or 0x01000000. drivers/mtd/maps/solutionengine.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) --- linux-next-20180717.orig/drivers/mtd/maps/solutionengine.c +++ linux-next-20180717/drivers/mtd/maps/solutionengine.c @@ -59,9 +59,9 @@ static int __init init_soleng_maps(void) return -ENXIO; } } - printk(KERN_NOTICE "Solution Engine: Flash at 0x%08lx, EPROM at 0x%08lx\n", - soleng_flash_map.phys & 0x1fffffff, - soleng_eprom_map.phys & 0x1fffffff); + printk(KERN_NOTICE "Solution Engine: Flash at 0x%pap, EPROM at 0x%pap\n", + &soleng_flash_map.phys, + &soleng_eprom_map.phys); flash_mtd->owner = THIS_MODULE; eprom_mtd = do_map_probe("map_rom", &soleng_eprom_map);