Received: by 10.223.164.202 with SMTP id h10csp4788957wrb; Wed, 29 Nov 2017 11:53:20 -0800 (PST) X-Google-Smtp-Source: AGs4zMa3CJyQeqUO3xo/v0c3F+OZ9yZb6LDVxATUkoB+N2Fk0DRu8soIm7lHDMXLFTG6UeNqnV2b X-Received: by 10.84.130.67 with SMTP id 61mr19395plc.368.1511985200779; Wed, 29 Nov 2017 11:53:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1511985200; cv=none; d=google.com; s=arc-20160816; b=YsWBAsM4pXHeoRrisSaY4kwptxNfkZUIFIilnl9mf+AaUHkXFUKJ7KWCfwquYmNWpZ iqETf1ZdbwTNH0yZcafxGjey8Hizg5e+rpvd1h/4C/4/ypOA9mlXbUxI775uWjP/xNM+ 6QTn0PBxxf0awtxnKkkuULSnla6diqj3pAxyRcgR9UCPC3VK5MzhNrsXFBp6Qtjs/+m/ IvNU6Ip17irKOtweNdFl55XIjL4dijB0ekM0OCVFKbL7JzyoRM1kak6oS+lg0lKVa0IH de0BH78yKy1qpue8fhjkmyZ7tJ2R/o3kJrt0QoLmX3rzX7/E+lvYCNdw+2s+bwpuie4T zGuQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:organization:from:references:cc:to:subject :arc-authentication-results; bh=1OZwsG0tAD+JdPbK/fjYikvhxCsfpBhL8zob053KblM=; b=etmdGRz1uNdwzLGR7zu02DExFd/W747K+6Wd2eKnVnGAsC2fkbOR0Hb9q2Wb3sm96u JllpOZwm6quU/L8mbY/CpBHOFQ8bsq8P5AW27SoWU13hP29Hr8ZU/rX5dzOwoQskJ3F6 76F2nIc/5B55+UN5qf+6e7Tq+eUXxjwcd6OJLP5bGNvfcWHoD4ed3PMH7d0Y/qY2xL8M kyc2F4vb1ekBIgkwHB7gMweZq3WHs8fD5CCgoD8rZn/SCMe0V8cdtzmWPcYwZwsM7kFC tZTjVSwC8DfULDHD6je3K2wvPetdjSdvIMqfXOf0piqT4/5uFNm4Ig+I80RBiI4Izg3R UUKQ== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n187si1725104pga.318.2017.11.29.11.53.07; Wed, 29 Nov 2017 11:53:20 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752665AbdK2Tvf (ORCPT + 99 others); Wed, 29 Nov 2017 14:51:35 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:39522 "EHLO aserp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751980AbdK2Tve (ORCPT ); Wed, 29 Nov 2017 14:51:34 -0500 Received: from userv0021.oracle.com (userv0021.oracle.com [156.151.31.71]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id vATJpBwJ003728 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 29 Nov 2017 19:51:12 GMT Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by userv0021.oracle.com (8.14.4/8.14.4) with ESMTP id vATJpAtl003715 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 29 Nov 2017 19:51:11 GMT Received: from abhmp0002.oracle.com (abhmp0002.oracle.com [141.146.116.8]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id vATJpAnb002533; Wed, 29 Nov 2017 19:51:10 GMT Received: from [10.135.190.159] (/10.135.190.159) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 29 Nov 2017 11:51:10 -0800 Subject: Re: [Xen-devel] [PATCH] Xen/pciback: Implement PCI slot or bus reset with 'do_flr' SysFS attribute To: =?UTF-8?B?UGFzaSBLw6Rya2vDpGluZW4=?= Cc: Jan Beulich , Konrad Wilk , Juergen Gross , xen-devel@lists.xenproject.org, Boris Ostrovsky , linux-kernel@vger.kernel.org References: <20171106174842.20276-1-Govinda.Tatti@Oracle.COM> <5A01D3F3020000780018CE86@prv-mh.provo.novell.com> <8940b38d-715c-9fcb-cc74-46574d416703@oracle.com> <5A041FB9020000780018D6E8@prv-mh.provo.novell.com> <5A1EE1D50200007800193318@prv-mh.provo.novell.com> <20171129180529.GQ20756@reaktio.net> From: Govinda Tatti Organization: Oracle Corporation Message-ID: <6a28becf-8142-9fcb-71a8-583ea69001ee@oracle.com> Date: Wed, 29 Nov 2017 13:51:06 -0600 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: <20171129180529.GQ20756@reaktio.net> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Source-IP: userv0021.oracle.com [156.151.31.71] Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/29/2017 12:05 PM, Pasi Kärkkäinen wrote: > On Wed, Nov 29, 2017 at 11:25:09AM -0600, Govinda Tatti wrote: >>>>> Furthermore, contrary to what you claim in >>>>> your reply to Pasi, I can't see where you try an actual FLR first - >>>>> you go straight to pci_probe_reset_{slot,bus}(). If you actually >>>>> tried FLR first, only falling back to the other methods as "emulation", >>>>> I could certainly agree with the file name chosen. >>>> Currently, multiple resets are being invoked (independently) in the context >>>> of "xl attach/detach/shutdown/reboot". >>>> >>>> - pci_reset_function_locked (invoked by pcistub_put_pci_dev()) >>>> This function tries various PCI reset methods including FLR. >>>> - pcistub_reset_dev (called by toolsstack based on "do_flr" attribute) >>> While related in a certain way, I can't really see how this addresses >>> the comment. >> pcistub_reset_dev() just tries slot or bus reset but not FLR since it is >> being >> checked and executed by pci_reset_function_locked() if supported. May be we >> can >> add FLR reset code to pcistub_reset_dev() and try FLR first before fall-back >> to >> slot/bus reset. >> > Hmm.. is the suitable reset method something that can be figured out automatically? > > I mean if FLR is tried first, but it isn't supported by the device, is it OK to go ahead and do a slot/bus reset automatically? Yes, we are moving in the same direction. > What if there are other devices in the same bus, wouldn't automatic bus reset be a bad thing? We will perform BUS or SLOT reset only if all device/functions behind the bus/slot are owned by pcistub. Otherwise, we will skipthis reset. > Or should the reset-method be configured by the user for the VM / PCI device ? > > Just thinking out loud here.. > Cheers GOVINDA From 1585430974095385005@xxx Wed Nov 29 19:46:40 +0000 2017 X-GM-THRID: 1583346318922306893 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread