Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp1518827pxb; Wed, 20 Oct 2021 06:44:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxaOlp5Obf5OLJHuuwrmba1vrDtgUAwcwSOGD8M1Z3tc1WDNcV+kMf+/nZd7M9zXU0LKGGh X-Received: by 2002:a63:ef57:: with SMTP id c23mr103952pgk.60.1634737480831; Wed, 20 Oct 2021 06:44:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634737480; cv=none; d=google.com; s=arc-20160816; b=TpLV/P9N5xD78smg81ZC+OI5N+qZTUMDnJRDVA+9cHZw5+KU2JVIVO0d8hIqcOFAnN n8qwYew+kqWUxjnJ6mmLXgirciJEeq6fkY5x5iR2a+3187p7ZpjZxgyCrQbkd98Uuaqp OgWWQtVyJ6t5RVc6dUJ5LRo5H+YoBdt44r/2FSBqsWNo9ZnJhsGfghw7fPj/iZE1EECE rxPIWCyswne0+LbdFYBw6Z/W0I8rCml3VVUlctVJrTibkIYq77HfM2jkla354WlRJTph dFvFwZIKSHMNRhbQ9XtmBMoBfw1z40zSHTCITT4+6AG/QcRKjeBFTKLJuCYztu1aYtgS looQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=R+f9jX4gENJ9ZTepD8KkqshKnHoLg5Qaf4KS0HjJ+5g=; b=PIEYJGfK9LhkrtEh2UeAbEk1fsEtrNt+RhysUrNNXBBaBfA4uCSTaguRN0kQQu766y RBw4XYBjKSNWqU3Ivex2RdgbK/VAhGzDwjTr1Oanq4VgxQeLi+pi5Z5pmtpuNZGLqiK2 bCqZISyhkgn21uA+/W/UZm+EI5+5X8UUXJGPpT8bOBbRWMcSIFMqUk7ji08kC9taPXQT wHk4bfN/pIJp9BWPGEO4l39qI6ty+IXc/A6LySmKwQOnzVU9kpbxDq29dQPDR1aml+yW jkN7d/eapEyTUt1qn2YyY/T+7Xtq9JH4sKqXoWLsUi6nw/CvVD/Gtvw1bwC7qrjC9lt3 mBZw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c12si3143327pfc.220.2021.10.20.06.44.20; Wed, 20 Oct 2021 06:44:40 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230020AbhJTNnr (ORCPT + 99 others); Wed, 20 Oct 2021 09:43:47 -0400 Received: from mail-oi1-f175.google.com ([209.85.167.175]:46853 "EHLO mail-oi1-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229639AbhJTNnr (ORCPT ); Wed, 20 Oct 2021 09:43:47 -0400 Received: by mail-oi1-f175.google.com with SMTP id o204so9630883oih.13; Wed, 20 Oct 2021 06:41:32 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=R+f9jX4gENJ9ZTepD8KkqshKnHoLg5Qaf4KS0HjJ+5g=; b=hmDTM4imIOVluJqVeOEtsi2VHf2gmChp5WS+X3FGKhMMsKW4dGNf26BQFQK2YWLd8L VFHFtzADPmTuRuiCFZCFaKrDzVXmqung9Mv5kgGi4/RZ9tL6UNx5AB+SXayL3Rh6Ee2A Sw3hTGPk+8PHYDhXEy1zGuecJ7dhrEvMg9qdFTcDKDg4GNWledZJILSCEqW2uS6/CI4g mUN6xIyq79Gwf9b2yW+12dF3WQ6UyQ5Pro+5DfI0oP0bZy6esE6QPVdaSJWnssWUp63W c5C9eyICXOK8TeHfUfE5uhtW2JNjnLv6OQGGSU3nWvcbs3Ouq5I4CyexmkNFl79K2idh qMTw== X-Gm-Message-State: AOAM532uWNrmy41njGBQOk6dihm7jdlMFGFeqBszyLVsyVOdVL7EIJ0X s+ZgsdIZtTwFuRC8WISeTjvXu/aOBA== X-Received: by 2002:a05:6808:2389:: with SMTP id bp9mr9574873oib.140.1634737292382; Wed, 20 Oct 2021 06:41:32 -0700 (PDT) Received: from robh.at.kernel.org (66-90-148-213.dyn.grandenetworks.net. [66.90.148.213]) by smtp.gmail.com with ESMTPSA id s18sm465022otd.55.2021.10.20.06.41.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Oct 2021 06:41:31 -0700 (PDT) Received: (nullmailer pid 2247038 invoked by uid 1000); Wed, 20 Oct 2021 13:41:30 -0000 Date: Wed, 20 Oct 2021 08:41:30 -0500 From: Rob Herring To: Naveen Naidu Cc: bhelgaas@google.com, linux-kernel-mentees@lists.linuxfoundation.org, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, Pali =?iso-8859-1?Q?Roh=E1r?= Subject: Re: [PATCH v2 02/24] PCI: Set error response in config access defines when ops->read() fails Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Oct 15, 2021 at 07:58:17PM +0530, Naveen Naidu wrote: > Make PCI_OP_READ and PCI_USER_READ_CONFIG set the data value with error > response (~0), when the PCI device read by a host controller fails. > > This ensures that the controller drivers no longer need to fabricate > (~0) value when they detect error. It also gurantees that the error > response (~0) is always set when the controller drivers fails to read a > config register from a device. > > This makes error response fabrication consistent and helps in removal of > a lot of repeated code. > > Suggested-by: Rob Herring > Signed-off-by: Naveen Naidu > --- > drivers/pci/access.c | 10 ++++++++-- > 1 file changed, 8 insertions(+), 2 deletions(-) Reviewed-by: Rob Herring