From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pg0-f68.google.com (mail-pg0-f68.google.com [74.125.83.68]) by dpdk.org (Postfix) with ESMTP id 2C8BE1B1AF for ; Fri, 16 Feb 2018 21:09:58 +0100 (CET) Received: by mail-pg0-f68.google.com with SMTP id e11so3236503pgq.12 for ; Fri, 16 Feb 2018 12:09:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=2H1s2RlAs6+YYS3z1QLW5Ny4YtyLxK4rj4bQyXy6now=; b=1o7jhu6LTS/SI6pz4iWrDWqbLLDiRxhjv6ex3Dn7KuDbF6tWYUHvuh5SpKOSfZL9Pj 2xSW4choPM6YAQBAgCrJbIZ/e5ylp23j6z2EA5kwCAicMNr3vhDttR01/cLKBuo9b8CQ ClLH7kTTsXdhWs8g1/CsS2dv2pk0F4A5Vrl/XoMsHIF7te3dgOom2qhwHIbgSiBmqCi+ pjC1mVz0bMAzvKruCLndUwfeuxMWLrUZQFk9XzatE82d2hKN9rJkGc//rTEuBeOUAEbg Y8t2Q8c8Z361eg3sBoKxH8MD+SIKOh6+is0zDSBiLUehV3QPr1ZXn4dBn0aOv2zEpOWB lP8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=2H1s2RlAs6+YYS3z1QLW5Ny4YtyLxK4rj4bQyXy6now=; b=o1BdmopHu/DW1Hv+9JSLFrOJ/GMhGpn04HkKX0o8sFBaEAaDtVrkyjNxYfajgwh94b PsWGHyE7P2WGUivjsTw1uKUQj0624wBexRyg+vBF5YkD3BLH0WMNcVIvkAV/BFw2ziJ4 i+gvjv0clJBeB5pdN29dGZZtE4OrTXMTblaQD/WTu84c/Vh3H2UliB1ftkh78hysns/e 9t1O4OO8Zso63ez4REtdM7IngQQEJzXKJ+yTtClrxQRQBU4HK0TPIepUradc3pkGc4pf mFPaduXoYuEr+HkOs7zPrOV8NLB/31A6g9kwvFw1EhJIOhuH41FWwu9Q+c1syzxZ9eib zI1Q== X-Gm-Message-State: APf1xPAO6AHs0AaTwxzyI7O3EEvDGQyDhTi2E+8Rn652eKzHwADrER0P SBkuzbfgatQ38qezEJQBhjC0tQ== X-Google-Smtp-Source: AH8x227SI440qxaFVPWhmMzDmCb3d0miLO6AL2gnzL+/bckd0KnCuQ25luqCqsQH5K9WAGHuktQ1lg== X-Received: by 10.99.103.129 with SMTP id b123mr5918610pgc.177.1518811797288; Fri, 16 Feb 2018 12:09:57 -0800 (PST) Received: from xeon-e3 (204-195-71-95.wavecable.com. [204.195.71.95]) by smtp.gmail.com with ESMTPSA id z127sm17907099pfb.130.2018.02.16.12.09.57 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 16 Feb 2018 12:09:57 -0800 (PST) Date: Fri, 16 Feb 2018 12:09:54 -0800 From: Stephen Hemminger To: alangordondewar@gmail.com Cc: cristian.dumitrescu@intel.com, dev@dpdk.org, Alan Dewar Message-ID: <20180216120954.7c913074@xeon-e3> In-Reply-To: <1518795853-7726-1-git-send-email-alan.dewar@att.com> References: <1507195258-14766-1-git-send-email-alan.dewar@att.com> <1518795853-7726-1-git-send-email-alan.dewar@att.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [RFC v2] sched: parameterize QoS traffic-classes and queues X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Feb 2018 20:09:58 -0000 On Fri, 16 Feb 2018 15:44:13 +0000 alangordondewar@gmail.com wrote: > > +static inline uint32_t > +rte_min_pos_n_u16(uint16_t *x, uint32_t n) The table (x) is const > +{ > + uint32_t index; > + uint32_t min_index = 0; > + uint16_t min_value = UINT16_MAX; > + > + for (index = 0; index < n; index++) { > + if (x[index] < min_value) { > + min_value = x[index]; > + min_index = index; > + } > + } > + return min_index; > +} > + > #endif > > /*