From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bruce Richardson Subject: Re: [PATCH] eal/x86: implement x86 specific tsc hz Date: Mon, 4 Sep 2017 11:32:36 +0100 Message-ID: <20170904103236.GC16984@bricha3-MOBL3.ger.corp.intel.com> References: <20170823150027.70565-1-sergio.gonzalez.monroy@intel.com> <20170904102407.GA16984@bricha3-MOBL3.ger.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: "Gonzalez Monroy, Sergio" , "dev@dpdk.org" , "Ananyev, Konstantin" To: "Van Haaren, Harry" Return-path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id 0C8726841 for ; Mon, 4 Sep 2017 12:32:41 +0200 (CEST) Content-Disposition: inline In-Reply-To: <20170904102407.GA16984@bricha3-MOBL3.ger.corp.intel.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Mon, Sep 04, 2017 at 11:24:07AM +0100, Bruce Richardson wrote: > On Mon, Sep 04, 2017 at 10:38:08AM +0100, Van Haaren, Harry wrote: > > > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Sergio Gonzalez Monroy > > > Sent: Wednesday, August 23, 2017 4:00 PM > > > To: dev@dpdk.org > > > Cc: Ananyev, Konstantin ; Richardson, Bruce > > > > > > Subject: [dpdk-dev] [PATCH] eal/x86: implement x86 specific tsc hz > > > > > + > > > +static uint32_t > > > +check_model_wsm_nhm(uint8_t model) > > > +{ > > > + switch (model) { > > > + /* Westmere */ > > > + case 0x25: > > > + case 0x2C: > > > + case 0x2F: > > > + /* Nehalem */ > > > + case 0x1E: > > > + case 0x1F: > > > + case 0x1A: > > > + case 0x2E: > > > + return 1; > > > + } > > > > DPDK coding standards say /* fallthrough */ comments required when falling through cases. > > In this case I feel it would reduce readability, more than it improves it, but I recall > > some recent gcc/clang prints warnings if no /* fallthrough */ comments exist.. opinions? > > > > Same for switch() below. > > > > I see no warnings in this case with gcc 7.x. I don't think it counts as > a fallthrough unless there is code after the label - i.e. multiple > labels though technically fallthrough are treated as such by compiler. > apologies, typo: ... are NOT treated as such ...