From patchwork Wed Jun 5 02:16:33 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Yongjun X-Patchwork-Id: 2664231 Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 401EE3FC8C for ; Wed, 5 Jun 2013 02:16:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751728Ab3FECQf (ORCPT ); Tue, 4 Jun 2013 22:16:35 -0400 Received: from mail-wg0-f52.google.com ([74.125.82.52]:61911 "EHLO mail-wg0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751136Ab3FECQf (ORCPT ); Tue, 4 Jun 2013 22:16:35 -0400 Received: by mail-wg0-f52.google.com with SMTP id z12so206874wgg.19 for ; Tue, 04 Jun 2013 19:16:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:cc:content-type; bh=3TPE17lro4WLjUmRH7DUMnnEDjePl4vH2tR8wVTljZE=; b=iUJ4xL5K8n7exK3phZMOJiakz7gAVe7AnUsReuOglSnqUJT3JsqvzjKfMsjzYX9lqu 1QjbOMoWZ5j+1wS/O3xOOCSqKULbvmH1P4ptxwC4gHT544kQTiARHFqZOjMdBTkGMpaR nsW2w6lDXzctZ6/7i0cQ1smv4+vUA9r96QywtiKVHEbs2eQ0NeY/vvwXgJ1XsHlfYlCC Try/SsfDKbgM8c/DCnoYFywgblYRqipn+k8n6QsOElxgvpst6PTZCxijVMR/3VSRYfoH e12qmGVN0K5To8wzP9rOgKpWllIAJjIqWz+CscMiVJ9DfgLxAAw2YMap0CwLzF3QGqXW 20+Q== MIME-Version: 1.0 X-Received: by 10.181.13.106 with SMTP id ex10mr1268089wid.16.1370398593423; Tue, 04 Jun 2013 19:16:33 -0700 (PDT) Received: by 10.194.103.38 with HTTP; Tue, 4 Jun 2013 19:16:33 -0700 (PDT) Date: Wed, 5 Jun 2013 10:16:33 +0800 Message-ID: Subject: [PATCH] iwlegacy: fix error return code in il3945_pci_probe() From: Wei Yongjun To: sgruszka@redhat.com, linville@tuxdriver.com Cc: yongjun_wei@trendmicro.com.cn, linux-wireless@vger.kernel.org Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org From: Wei Yongjun Fix to return a negative error code in the il3945_hw_set_hw_params() error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun Acked-by: Stanislaw Gruszka --- drivers/net/wireless/iwlegacy/3945-mac.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/net/wireless/iwlegacy/3945-mac.c b/drivers/net/wireless/iwlegacy/3945-mac.c index dce5e8f..9581d07 100644 --- a/drivers/net/wireless/iwlegacy/3945-mac.c +++ b/drivers/net/wireless/iwlegacy/3945-mac.c @@ -3727,7 +3727,8 @@ il3945_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent) * 5. Setup HW Constants * ********************/ /* Device-specific setup */ - if (il3945_hw_set_hw_params(il)) { + err = il3945_hw_set_hw_params(il); + if (err) { IL_ERR("failed to set hw settings\n"); goto out_eeprom_free; }