Received: by 10.223.176.5 with SMTP id f5csp849687wra; Wed, 7 Feb 2018 08:30:02 -0800 (PST) X-Google-Smtp-Source: AH8x224/AXl6AyTDx/UUiRnK3YjYq4eDxQm92jUqj7Inj3Z+XZAVIDPM7ly4eJo2awHxLxKyEKOW X-Received: by 10.99.99.198 with SMTP id x189mr5448843pgb.248.1518021002394; Wed, 07 Feb 2018 08:30:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518021002; cv=none; d=google.com; s=arc-20160816; b=W0um+Km2xVu68sTSu+bCcWnSHP6+aw1JPVtNGrZP/M5Ob24kzGsAfRikUF+E13+nOp 43neIL4nML/pSO8XuP1fA9KLCeuJ7l6c1orkxRbljRC8mBjpIhASVFAL/MjjuVKnCjNr Vk0SXDmTg5d5FcPMEdpiYm0W2w1UQsNcqJutzRqmup+tDdKGR6keGLMERjK9e4pxnY1h MMqxB4oVZHUJNcwx3IQC5SicJBUJqDag4sZbcQaxYoqlWkWbgVtJRz+RMcTPe50k2Mrt itg2uYAO2UooDGAM2kgmqQi59O96VkYMcDRXTvR41c/IyowOAmpr8Za/qbzE1QiuppyX BFeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:spamdiagnosticmetadata :spamdiagnosticoutput:mime-version:user-agent:references:message-id :in-reply-to:subject:cc:to:from:date:dkim-signature :arc-authentication-results; bh=txVlEs+FM8J07BEiW1IQz4PX39uUEWuyNeC1DBMtGvo=; b=jBBafx0T5QhAPaRXzdu4B6boxoMjWZ8Sb4KwoWvB9tCaG4h2rOxhw/5hgV7jzmN87T f3NAZwjeTg/YmWxTWMLPeNSsIzKs1EsDaWHk2GM1roA1M/LDB1CVACujnhQehXBt2qWX 70eZooGWpx5nm4/RdWo2xMuPjzjwYLLh8roPeT4Km8HWHk94DuMp4VjMAlj8pIy1KN06 3TfSueOcxQbs9w/1R90EH14ltzSQ2x2egCtU8H3TS/oy9M86UOzOMqPxgzyW5WGobSWT hz2LGECf5EqAFwel4s6Rvo9uXSXxwv5VMgBD0hBv/xRVswrtCnv/jjwcmxMuo7XfMsfH 5MBQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@CAVIUMNETWORKS.onmicrosoft.com header.s=selector1-cavium-com header.b=iUerq6FP; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y12-v6si1256129plt.1.2018.02.07.08.29.48; Wed, 07 Feb 2018 08:30:02 -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=@CAVIUMNETWORKS.onmicrosoft.com header.s=selector1-cavium-com header.b=iUerq6FP; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932101AbeBGQ1V (ORCPT + 99 others); Wed, 7 Feb 2018 11:27:21 -0500 Received: from mail-bl2nam02on0062.outbound.protection.outlook.com ([104.47.38.62]:37920 "EHLO NAM02-BL2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754231AbeBGQ1T (ORCPT ); Wed, 7 Feb 2018 11:27:19 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=txVlEs+FM8J07BEiW1IQz4PX39uUEWuyNeC1DBMtGvo=; b=iUerq6FPN9eqyMADkLrot0mZdo/HWCbExPFhfg6kiwnTYnLuO3KrxLJ8wd8a+nFEPcAMvrnGq3VUSucJmeP91eU7wI60fuMzEF/RLzsV4n0TYWKsk55mnCZHAwv0A/3VDXDAyB0idMezvcgk6DEhYSFIdJiaaCCwN5AH0+/h3bo= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Chad.Dupuis@cavium.com; Received: from [192.168.1.225] (100.0.162.75) by BN6PR07MB2771.namprd07.prod.outlook.com (10.173.27.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.464.11; Wed, 7 Feb 2018 16:27:12 +0000 Date: Wed, 7 Feb 2018 11:26:43 -0500 (EST) From: Chad Dupuis X-X-Sender: cdupuis@administrators-MacBook-Pro.local To: Arnd Bergmann cc: linux-scsi@vger.kernel.org, "James E . J . Bottomley" , QLogic-Storage-Upstream@cavium.com, "Martin K. Petersen" , Nicolas Pitre , Andi Kleen , Saurav Kashyap , Arun Easi , Nilesh Javali , linux-kernel@vger.kernel.org Subject: Re: [PATCH 6/6] scsi: qedf: use correct strncpy() size In-Reply-To: <20180202131225.1658853-7-arnd@arndb.de> Message-ID: References: <20180202131225.1658853-1-arnd@arndb.de> <20180202131225.1658853-7-arnd@arndb.de> User-Agent: Alpine 2.00 (OSX 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Originating-IP: [100.0.162.75] X-ClientProxiedBy: CY4PR16CA0026.namprd16.prod.outlook.com (10.171.216.13) To BN6PR07MB2771.namprd07.prod.outlook.com (10.173.27.145) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 71d53cfa-c09c-4968-19bb-08d56e47a5b6 X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(7020095)(4652020)(4534165)(4627221)(201703031133081)(201702281549075)(5600026)(4604075)(2017052603307)(7153060)(7193020);SRVR:BN6PR07MB2771; X-Microsoft-Exchange-Diagnostics: 1;BN6PR07MB2771;3:xA0D6tXIBXvLTLXS57UhL7Kpb7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02zzqRahIWxf30Cu2+Uqm3vA50P4CE9EGMVRtaWaZyWaOTAov/UztP0GWW6ayXlBztEx5TtNGEEinPco4FEpz8vQTf2EQhBKa43qyQb7C8QrKC1Wd3je1Lt2rKwvvwQXnwVAr32knpv3zmDHfz+nErum5H/QpQ6R4YMU0uMweOphLnl6TW2pdW9l7zLOwlZ7dEIZlIzwwlQYdxyEvIiI9zz2w6fCJ5kQe+rfCyF+3De1zUjSnJoD2Q5Qqbk8TH3Fop4TA/KU+VXTrD+A0DtkqrTp6P+l9TolZ+J/PD+No7Qi3k45R8wlo;4:8nmv0sFqg6XKGL2M59mepDztwYvjSvuW2powzOpytn1IjKyN1nkbsNHIE+OqT+mQwGp3IPex+8JVhtC2bIZFfckwOqXdrZvQrk7yDqRnkAe6U7oxNQVbz90RooaqengG41K6bP9J8gWIKo83W56Q1MOpHG08Ir7bw5Nnhm986v9p2AtqSY2uhCocItm8FWE8VfxUXhNvpBXj1jfRD9ZmBKmId82CxN7GtUu85AKCre1KMw8whOpRVQ7O9xVA9vYLmC5lXNBbtywen8VgD7E+dj4qcokdxyB522jlKFVkhRY+oXFuxks9BjnWMK4TAcEZ X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(192374486261705); X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040501)(2401047)(8121501046)(5005006)(93006095)(93001095)(10201501046)(3002001)(3231101)(2400082)(944501161)(6041288)(20161123562045)(20161123560045)(20161123564045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(6072148)(201708071742011);SRVR:BN6PR07MB2771;BCL:0;PCL:0;RULEID:;SRVR:BN6PR07MB2771; X-Forefront-PRVS: 0576145E86 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(6049001)(366004)(39860400002)(376002)(346002)(396003)(39380400002)(189003)(199004)(9686003)(53936002)(68736007)(6246003)(386003)(76176011)(33896004)(106356001)(97736004)(52116002)(4326008)(25786009)(8936002)(105586002)(16576012)(54906003)(58126008)(26005)(2950100002)(6666003)(316002)(16586007)(47776003)(59450400001)(6916009)(229853002)(66066001)(5660300001)(305945005)(7736002)(117156002)(90366009)(186003)(5005980100005)(77096007)(16526019)(478600001)(81166006)(81156014)(6486002)(83506002)(23726003)(3846002)(86362001)(6116002)(98436002)(72206003)(8676002)(2906002);DIR:OUT;SFP:1101;SCL:1;SRVR:BN6PR07MB2771;H:[192.168.1.225];FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;BN6PR07MB2771;23:/MmXRodrLSRPzPofTWVObRU5x5KqN/Ga5+trg6zKQ?= =?us-ascii?Q?15vNrOL0IiZCh+PhLeYu8is6Uqfs5xaeMOkjgGxq9up8HSY82MCXo2W9VQ1J?= =?us-ascii?Q?IRSvQIksAqCG+7IlQZJhLSlvGTQOWpC9Utyd2qhDu7hRq3Y0hoKTnFNDo1Cl?= =?us-ascii?Q?XFWg3XN8c0HErjZyjh+G4ga8GqpFuqhS+KODckibOA4+7UQvzV5QfbxpE39Q?= =?us-ascii?Q?zBIs0e7f9thtES4+Ej0at8pOtYU0c26VaZOSvserKq3T6qxS+/mJA7PnMVYT?= =?us-ascii?Q?J23YTQ+9KoIxWjQeMMyRS0dtCde9P+h+sI2gp94kttTGjnaY4+ZJcrmTpyVa?= =?us-ascii?Q?IvUJY8mtRQtMrIK1vhqj1VK1BeO/PThXxVVfntEjx2MRuukqioaiL+7cbm5w?= =?us-ascii?Q?LpPTTuqwNqdjCjoJhj9oymzloRhMOTWCQ4dLzOfbPXt7TYH4ZLj+cgt++ov/?= =?us-ascii?Q?NZ9SKw13/yEqOwoVyAT+FLCkzrmkFix5AhDTFONChsvBdI3pGsYsaz6LQKrj?= =?us-ascii?Q?o5fNkOhtI4lSPY55WrvBC/ZInxpb63MZGpvFoAWLsPsfwUuYTQARhJwV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U5cOnZtYljqmNVr5lom1bYbR3BPhlWsXn1VhhcQ06OuR/C70J83re/NuFqanG9LC4BShZ0nyiuZxICYZqi3kfXk80rZozgKbYk5fPM+zhP5tIuNtM7oyYSYgcXMNvcGao0l/AvkWoYNZGTw0Ja/e4NCzYnhzN4IQckrUa+bkOSZE4jg2aQkAZSvG+OzjjYoEVC73Yuf/EfE840qTP1hXPljCuaxwR6qOl9SRoAy5onyjVBvokhuIyBIv3ajC7LnSMBx/hScMvunh9/Ko=;5:RCDXiAnRpsk7S/OuCHun507hxRSvvFAo/pXVUHjiMhiKq7XQ3HsMBvremiaPGrzqnAKAJU9w3fjYqjm3uTMUGQOrZHS7jfrKiEwrmgqAHWm0Ce47tlWRYdY5wrmnWw551wS840eVYMaA8fv3D9lxonGZiLte4tHvYWZ5rxXy1/Q=;24:ycFhheyn+qZqdOZADBQqtfL3nzdlBm672kewnQtokzQYYNOxROMMFscJh43uFeSp8kgtE+MTPIdKRL/67D4k6toWW+rWoXsTQDollN9owFU=;7:9jyeuQ4pgVELf/epjA3HsrMxlZsrjn0lunO/2BfLfPOaxKrhP+kUCfXfAGGUdV5WjXu0mouo5CfaH3ch7VJm4SAi8Jb2jENqjrXuIEyeQ3sS526a46+ayAFFdX8p/hPEdiypxWSR1oAxOtX0P3j5+6+ICDo464P/UlScNxjquc7Lkgah8K0+FWQpdMSrpDPlq23ALOXo2WJQtpWdXHMfIqtc+fD8nUCVUKdIs77OGADwe3YpehxywlwGnSmk4Hvf SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Feb 2018 16:27:12.7826 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 71d53cfa-c09c-4968-19bb-08d56e47a5b6 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR07MB2771 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 2 Feb 2018, 8:12am, Arnd Bergmann wrote: > gcc-8 warns during link-time optimization that the strncpy() call > passes the size of the source buffer rather than the destination: > > drivers/scsi/qedf/qedf_dbg.c: In function 'qedf_uevent_emit': > include/linux/string.h:253: error: 'strncpy' specified bound depends on the length of the source argument [-Werror=stringop-overflow=] > > This changes it to strscpy() with the correct length, guaranteeing > a properly nul-terminated string of the right size. > > Signed-off-by: Arnd Bergmann > --- > drivers/scsi/qedf/qedf_dbg.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > Reasonable security precaution. Acked-by: Chad Dupuis