From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <ziye.yang@intel.com>
Received: from mga09.intel.com (mga09.intel.com [134.134.136.24])
 by dpdk.org (Postfix) with ESMTP id 209A79AAE
 for <dev@dpdk.org>; Thu, 19 May 2016 15:15:02 +0200 (CEST)
Received: from orsmga001.jf.intel.com ([10.7.209.18])
 by orsmga102.jf.intel.com with ESMTP; 19 May 2016 06:15:02 -0700
X-ExtLoop1: 1
X-IronPort-AV: E=Sophos;i="5.26,334,1459839600"; d="scan'208";a="958054146"
Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204])
 by orsmga001.jf.intel.com with ESMTP; 19 May 2016 06:15:02 -0700
Received: from fmsmsx158.amr.corp.intel.com (10.18.116.75) by
 FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS)
 id 14.3.248.2; Thu, 19 May 2016 06:15:01 -0700
Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by
 fmsmsx158.amr.corp.intel.com (10.18.116.75) with Microsoft SMTP Server (TLS)
 id 14.3.248.2; Thu, 19 May 2016 06:15:01 -0700
Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.104]) by
 SHSMSX151.ccr.corp.intel.com ([169.254.3.116]) with mapi id 14.03.0248.002;
 Thu, 19 May 2016 21:14:59 +0800
From: "Yang, Ziye" <ziye.yang@intel.com>
To: Thomas Monjalon <thomas.monjalon@6wind.com>
CC: "dev@dpdk.org" <dev@dpdk.org>
Thread-Topic: [dpdk-dev] [PATCH] pci: Add the class_id support in pci probe
Thread-Index: AQHRsbn5usy/YtXBNEyKW1iPokucdJ/ALTtA//+FJoCAAIpQwA==
Date: Thu, 19 May 2016 13:14:58 +0000
Message-ID: <FA6C2217B01E9D48A581BB486602101401758FF3@shsmsx102.ccr.corp.intel.com>
References: <1462946895-49958-1-git-send-email-ziye.yang@intel.com>
 <1727235.C3RSOGSy8E@xps13>
 <FA6C2217B01E9D48A581BB486602101401758FC6@shsmsx102.ccr.corp.intel.com>
 <243965117.o52RgkbZZP@xps13>
In-Reply-To: <243965117.o52RgkbZZP@xps13>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach: 
X-MS-TNEF-Correlator: 
x-originating-ip: [10.239.127.40]
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
Subject: Re: [dpdk-dev] [PATCH] pci: Add the class_id support in pci probe
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: patches and discussions about DPDK <dev.dpdk.org>
List-Unsubscribe: <http://dpdk.org/ml/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://dpdk.org/ml/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <http://dpdk.org/ml/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
X-List-Received-Date: Thu, 19 May 2016 13:15:03 -0000



-----Original Message-----
From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com]=20
Sent: Thursday, May 19, 2016 8:57 PM
To: Yang, Ziye <ziye.yang@intel.com>
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH] pci: Add the class_id support in pci probe

2016-05-19 12:18, Yang, Ziye:
> From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com]=20
> 2016-05-11 14:08, Ziye Yang:
> > +	dev->id.class_id =3D (uint32_t)tmp && CLASS_ANY_ID;
>=20
> Should be a bitwise &. Why masking is needed?
> [Ziye]  Only 24bit info is needed.

What are the other bits?
Please put a comment in the code.
[Ziye] Revision ID is defined in pci spec, classid has 24 bits. And when  w=
e read from the system, we will only get class_id, subclass and program int=
erface. I will put the comment