Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp4233581ybb; Tue, 7 Apr 2020 03:30:45 -0700 (PDT) X-Google-Smtp-Source: APiQypLtUxU6g+B+tWMlrkKWDAPRCmDDbpyR3N3rXACVPhxAacpqO1J2dION1jhOiyxBp1fImvAx X-Received: by 2002:a9d:12cc:: with SMTP id g70mr907468otg.115.1586255445042; Tue, 07 Apr 2020 03:30:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586255445; cv=none; d=google.com; s=arc-20160816; b=Wx6871PQTT3+QN//exguoDHMlxA3tgL9qP39Pi9mNKFzqJjrfW4UOic+i4BLuTYWCf WDROVETl3GZ4n09p9XyNRfmJmhgc6g6lXTsgDIze6iXr2/P9uoSe2zq9x5Or9X5hnbKS fzG/JTglVe10P/wPUVVdHEvx6ihdTlFzjr5ZFF41kD11sq6Tyiz873dWvRW7RA97/bjw 26SWDdclQC2+2QDuWBlxGFXvY8YG7hLtKDSXENevMNi7BTvHpAsrGlIHZ2MgqKn4Ixp2 +9ALjQlakyWuh4ylpxt82yrUELgHfZtZNGpb1lS/XahWpSgRVHMtMHELb7VSorHh/f6j KBFQ== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=QV4jQHffeMWDNX2bzypZWoKVQpW5A80AkLLszHUt8to=; b=0010pCCDZoxbKRXe5RI2bdrBfMcqtGwb8a+duTWpiUF8/R4odpJxy+MvEzgojX+2XB QrajOEdI2YiuA8SE5IbXAVBeK8j5MVbNpKLfPpuZLgifLikvjdVnKZet5aWy2Zg6Pmdh JnNm0+vdJPFZ2r3sm3EKbRpK0oansgiA2JE+LX5fhyux5NcbIYbXX0SGBRdgzlZHeQGw /9pNeESYzwpDLOdMMx/BJ8Xvabucq70hCZbRSeLtyO+/d/jzs7kZv2v654/vo63RXVbL VXq2RC1bmNgaIU97y0biqBPmK73Z3TIGNZqReFM6552m7zuATB53aruHrxIShOSSeAc5 ef2g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=1zEry82I; 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 x73si1032013ooa.13.2020.04.07.03.30.33; Tue, 07 Apr 2020 03:30:45 -0700 (PDT) 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=@kernel.org header.s=default header.b=1zEry82I; 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 S1728783AbgDGKYq (ORCPT + 99 others); Tue, 7 Apr 2020 06:24:46 -0400 Received: from mail.kernel.org ([198.145.29.99]:35048 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728747AbgDGKYn (ORCPT ); Tue, 7 Apr 2020 06:24:43 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2744A2082F; Tue, 7 Apr 2020 10:24:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1586255082; bh=khVOaY2ujlcX/REye0ztyWAGD+5eMAaXklsRDjNbiUc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=1zEry82Ikal49LncbaqmuFMxrQQbU9fQ4wIc1/Qexu8nGPjEeWU661mRmavEe4Xl0 FfA4DMOqAh/JaX39BAy5LlOx372QOwSc0Qxx8CcYIQJ5iDvJcRwcwr4+0UTpAQxbrv 5/FH1o1sf46qtIqGz+FruwDxeLXKfYlp1i1U2ras= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Kishon Vijay Abraham I , Lorenzo Pieralisi Subject: [PATCH 5.5 22/46] misc: pci_endpoint_test: Fix to support > 10 pci-endpoint-test devices Date: Tue, 7 Apr 2020 12:21:53 +0200 Message-Id: <20200407101501.881056561@linuxfoundation.org> X-Mailer: git-send-email 2.26.0 In-Reply-To: <20200407101459.502593074@linuxfoundation.org> References: <20200407101459.502593074@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Kishon Vijay Abraham I commit 6b443e5c80b67a7b8a85b33d052d655ef9064e90 upstream. Adding more than 10 pci-endpoint-test devices results in "kobject_add_internal failed for pci-endpoint-test.1 with -EEXIST, don't try to register things with the same name in the same directory". This is because commit 2c156ac71c6b ("misc: Add host side PCI driver for PCI test function device") limited the length of the "name" to 20 characters. Change the length of the name to 24 in order to support upto 10000 pci-endpoint-test devices. Fixes: 2c156ac71c6b ("misc: Add host side PCI driver for PCI test function device") Signed-off-by: Kishon Vijay Abraham I Signed-off-by: Lorenzo Pieralisi Cc: stable@vger.kernel.org # v4.14+ Signed-off-by: Greg Kroah-Hartman --- drivers/misc/pci_endpoint_test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/misc/pci_endpoint_test.c +++ b/drivers/misc/pci_endpoint_test.c @@ -633,7 +633,7 @@ static int pci_endpoint_test_probe(struc { int err; int id; - char name[20]; + char name[24]; enum pci_barno bar; void __iomem *base; struct device *dev = &pdev->dev;