From patchwork Wed Sep 13 07:32:15 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Allen X-Patchwork-Id: 9950499 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id C65916038F for ; Wed, 13 Sep 2017 07:33:10 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B8411283B0 for ; Wed, 13 Sep 2017 07:33:10 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id AD02C2872C; Wed, 13 Sep 2017 07:33:10 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.5 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SBL_CSS, RCVD_IN_SORBS_SPAM, RCVD_IN_SORBS_WEB,T_DKIM_INVALID autolearn=no version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 60FC9283B0 for ; Wed, 13 Sep 2017 07:33:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751976AbdIMHdC (ORCPT ); Wed, 13 Sep 2017 03:33:02 -0400 Received: from mail-pf0-f194.google.com ([209.85.192.194]:34854 "EHLO mail-pf0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751712AbdIMHcz (ORCPT ); Wed, 13 Sep 2017 03:32:55 -0400 Received: by mail-pf0-f194.google.com with SMTP id i23so2416842pfi.2; Wed, 13 Sep 2017 00:32:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=DpGZ8Uc9VTljocAhKUPO30H4SUOYuYwzn+Fg3wXVnCU=; b=V6wX8k4liKQ0OoRQDsNHboVyH2bCYcrSeeD5z0Gy+U7jN4nL6bZo2z/9Ivccm46TSI t5f04gG/NC7M8NZlfyi07Dr96xmPvF1rMA3YdysGShfvJY4KKX1CoFKX1gde0MGCwYo3 KwiIOrPxS82YV4eZuYdDMRFuuthfPKc1NL0dPnOVF+alXKseI13O6bZpiuluslxlYYmp O9GHxLMXrcipuQHNj5hFT0AVege7hvq1T5m7vAsKy27ZdxaT55gIOwBnROIO58uqrqNV jVDnCPjtFl/SuZDDuq77nQDbe3/Yxb0H/kaJTQWePOgZj0zqVhwtiD9XQuCeiny8CwDO TUxw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=DpGZ8Uc9VTljocAhKUPO30H4SUOYuYwzn+Fg3wXVnCU=; b=NxxQnMfB3+pyopMWVt0pq5OEoSkR1vaNhr4ERARXEkA1aIVlkh2y79KbYWNk14bfqW 7/fw6yuLd09ZlvvxfMIPM04Xk6tMX4zku+JQ/Zr6Oqy5YXGrBAMMDqyWPfX2cng3VWf1 Ai62+6TfV1Tt6qQwnTNg7ddzpmQ5woakBspnjMyEWnfqi/TZvkqegwKmUe3g0vDahmAo hzOFjtLNkvyWQVe/H3V18h6PHX9aFrEAxlLxyJJY9MafhkDp/cldZHErNY3DcZd2/ibb NUi+mNHWYfsddriHa7Mp1LABwxoKVxcqUXJ/bBYs5qjaXp3xHV1uHB0n6IYvge+Mf2Q1 6Paw== X-Gm-Message-State: AHPjjUib0zC7DRsWWK5xpnxZHvlUPnkxd72m0Pm8YGtiQLsTEdcvsNUH IoCztdEBhzzxbwWbP6YJTg== X-Google-Smtp-Source: ADKCNb6OM5GMHiJfceubon94d2ne7qvnJ9JVmZM8lqKS+1UuB0JUqJz6IfwiAI9l2lmRmwy+IV+wcA== X-Received: by 10.99.181.23 with SMTP id y23mr16966141pge.283.1505287973932; Wed, 13 Sep 2017 00:32:53 -0700 (PDT) Received: from localhost.localdomain ([103.42.74.194]) by smtp.gmail.com with ESMTPSA id u12sm17997328pfg.146.2017.09.13.00.32.49 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 13 Sep 2017 00:32:52 -0700 (PDT) From: Allen Pais To: linux-kernel@vger.kernel.org Cc: nouveau@lists.freedesktop.org, linux-crypto@vger.kernel.org, dri-devel@lists.freedesktop.org, MPT-FusionLinux.pdl@broadcom.com, linux-scsi@vger.kernel.org, netdev@vger.kernel.org, megaraidlinux.pdl@broadcom.com, target-devel@vger.kernel.org, linux-fbdev@vger.kernel.org, linux-btrfs@vger.kernel.org, Allen Pais Subject: [PATCH 06/10] drivers:ethernet: return -ENOMEM on allocation failure. Date: Wed, 13 Sep 2017 13:02:15 +0530 Message-Id: <1505287939-14106-6-git-send-email-allen.lkml@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1505287939-14106-1-git-send-email-allen.lkml@gmail.com> References: <1505287939-14106-1-git-send-email-allen.lkml@gmail.com> Sender: target-devel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: target-devel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Allen Pais --- drivers/net/ethernet/sun/cassini.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/sun/cassini.c b/drivers/net/ethernet/sun/cassini.c index 382993c..fc0ea3a 100644 --- a/drivers/net/ethernet/sun/cassini.c +++ b/drivers/net/ethernet/sun/cassini.c @@ -3984,7 +3984,7 @@ static inline int cas_alloc_rx_desc(struct cas *cp, int ring) size = RX_DESC_RINGN_SIZE(ring); for (i = 0; i < size; i++) { if ((page[i] = cas_page_alloc(cp, GFP_KERNEL)) == NULL) - return -1; + return -ENOMEM; } return 0; }