From mboxrd@z Thu Jan 1 00:00:00 1970 From: Richard Henderson Subject: Re: [RFC PATCH v2 10/15] cpu-model/s390: Add cpu class initialization routines Date: Fri, 20 Feb 2015 08:02:42 -0800 Message-ID: <54E75AA2.9070503@twiddle.net> References: <1424183053-4310-1-git-send-email-mimu@linux.vnet.ibm.com> <1424183053-4310-11-git-send-email-mimu@linux.vnet.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1424183053-4310-11-git-send-email-mimu@linux.vnet.ibm.com> Sender: linux-kernel-owner@vger.kernel.org List-Archive: List-Post: To: Michael Mueller , qemu-devel@nongnu.org, kvm@vger.kernel.org, linux-s390@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Gleb Natapov , Alexander Graf , Christian Borntraeger , "Jason J. Herne" , Cornelia Huck , Paolo Bonzini , Andreas Faerber List-ID: On 02/17/2015 06:24 AM, Michael Mueller wrote: > +/** > + * s390_test_facility - test if given facility bit is set facility list > + * of given cpu class > + * @class: address of cpu class to test > + * @nr: bit number to test > + * > + * Returns: true in case it is set > + * false in case it is not set > + */ > +bool s390_test_facility(S390CPUClass *cc, unsigned long nr) > +{ > + if (cc) { > + return test_facility(nr, cc->fac_list) ? true : false; > + } > + return false; > +} Where do you see this being used? r~ From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42868) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YOq2U-0002oQ-9v for qemu-devel@nongnu.org; Fri, 20 Feb 2015 11:02:54 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YOq2R-0006Fv-5v for qemu-devel@nongnu.org; Fri, 20 Feb 2015 11:02:50 -0500 Received: from mail-qc0-x22a.google.com ([2607:f8b0:400d:c01::22a]:43564) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YOq2R-0006Fl-2j for qemu-devel@nongnu.org; Fri, 20 Feb 2015 11:02:47 -0500 Received: by qcxr5 with SMTP id r5so1344075qcx.10 for ; Fri, 20 Feb 2015 08:02:46 -0800 (PST) Sender: Richard Henderson Message-ID: <54E75AA2.9070503@twiddle.net> Date: Fri, 20 Feb 2015 08:02:42 -0800 From: Richard Henderson MIME-Version: 1.0 References: <1424183053-4310-1-git-send-email-mimu@linux.vnet.ibm.com> <1424183053-4310-11-git-send-email-mimu@linux.vnet.ibm.com> In-Reply-To: <1424183053-4310-11-git-send-email-mimu@linux.vnet.ibm.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RFC PATCH v2 10/15] cpu-model/s390: Add cpu class initialization routines List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Michael Mueller , qemu-devel@nongnu.org, kvm@vger.kernel.org, linux-s390@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Gleb Natapov , Alexander Graf , Christian Borntraeger , "Jason J. Herne" , Cornelia Huck , Paolo Bonzini , Andreas Faerber On 02/17/2015 06:24 AM, Michael Mueller wrote: > +/** > + * s390_test_facility - test if given facility bit is set facility list > + * of given cpu class > + * @class: address of cpu class to test > + * @nr: bit number to test > + * > + * Returns: true in case it is set > + * false in case it is not set > + */ > +bool s390_test_facility(S390CPUClass *cc, unsigned long nr) > +{ > + if (cc) { > + return test_facility(nr, cc->fac_list) ? true : false; > + } > + return false; > +} Where do you see this being used? r~