From mboxrd@z Thu Jan 1 00:00:00 1970 From: Panu Matilainen Subject: Re: [PATCH v3 12/15] ether: extract function eth_dev_get_intr_handle Date: Fri, 16 Sep 2016 10:17:28 +0300 Message-ID: <62054083-94c6-d85d-3ab7-71c547117ccb@redhat.com> References: <1451682326-5834-1-git-send-email-viktorin@rehivetech.com> <1473410639-10367-13-git-send-email-shreyansh.jain@nxp.com> <1378dc00-7fa7-6679-1118-5992cfd1adfd@intel.com> <4310538.hvdbegMmPc@xps13> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org, viktorin@rehivetech.com, hemant.agrawal@nxp.com To: Thomas Monjalon , "Hunt, David" , Shreyansh Jain Return-path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 9C6E52B84 for ; Fri, 16 Sep 2016 09:28:07 +0200 (CEST) In-Reply-To: <4310538.hvdbegMmPc@xps13> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 09/15/2016 05:05 PM, Thomas Monjalon wrote: > 2016-09-15 14:02, Hunt, David: >> On 9/9/2016 9:43 AM, Shreyansh Jain wrote: >>> +static inline >>> +struct rte_intr_handle *eth_dev_get_intr_handle(struct rte_eth_dev *dev) >>> +{ >>> + if (dev->pci_dev) { >>> + return &dev->pci_dev->intr_handle; >>> + } >>> + >>> + RTE_VERIFY(0); >> >> Rather than RTE_VERIFY(0), might I suggest using rte_panic with a more >> relevant error message? > > RTE_ASSERT is preferred. > We must stop adding some rte_panic calls except for debug. +1 It wouldn't hurt to make that a hard rule. - Panu -