Received: by 10.223.164.202 with SMTP id h10csp1431269wrb; Wed, 15 Nov 2017 20:35:19 -0800 (PST) X-Google-Smtp-Source: AGs4zMaJlSas65YD4hb5W5BO0kgtxzoKYk+Pd6Ff5TPCkBIbSOkwsmbIVXyZQGEF4GHyX1VsXXXQ X-Received: by 10.159.204.147 with SMTP id t19mr434282plo.222.1510806919520; Wed, 15 Nov 2017 20:35:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1510806919; cv=none; d=google.com; s=arc-20160816; b=r0PEci0pVgs9BDt3vUxY7SCoqkKX3Zyx0oMnTV/zfYhEuIIo2iGcv5MP0FR5KN7TSh 2HERD0DsBDuBg4q2D8B9zD82uQLJFjPBa+p7tplVdE6VcUKxXehBJkCwt+N4w0T8s9aC N1Ch6iUpsklCislcLI2SxGdEap7xWhsWr/jN3Ci4CClBTvc/wHFz1EX2QtJ7cZ5Nhmv7 tFVh9s+VGIpZAsiIigw6MpByLcKP+wgdF6bN4xmSyxK2kux/7eUUuvQz69ib6gdBJKKV IaWWw4hPA/W358Ih1m08dJgFdHMe1j8fINEmorf1KJxLLAa27cmMKkw4hjsEH5m36glm KW9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=6pF6gwfTlKPSTJZDvrlF3yxeY1NYhMav+oF3TopfMzc=; b=sr+GbXGpWcFBLXAr18dUyBb9KC7P5lR8J1dq+IugUsYH4YUmrO9HLFM9Dxm3wsVVpe Vp+H0xrKCvlrKGJpLrGNkJIW1Qp7PC491aB286O0pd3GkyolDI5802jYQtSgb+D8WmC7 kitxKcNrhNA5AMFV01O1osexuG8srkwwS4uP3BwFDqs1Ol+KokrOKP2jtRuysO3FMEZc nilbQHC0LcsMcxDxJ9fianDhZ5f8ytnGqYFvfVePeWkYHmtpid2Y4qILJ1N6NxXfyeR/ R28cG7mZkOL7D2+8DZIFs0QGzlipHWvnyDWpBzCQex8XJgBJDvPSbjTViRcv3f0fXpnx irdA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=mi1K2KTr; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f3si203093pld.213.2017.11.15.20.35.07; Wed, 15 Nov 2017 20:35:19 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=mi1K2KTr; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759334AbdKPEdD (ORCPT + 89 others); Wed, 15 Nov 2017 23:33:03 -0500 Received: from mail-pf0-f196.google.com ([209.85.192.196]:49792 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932181AbdKPE3N (ORCPT ); Wed, 15 Nov 2017 23:29:13 -0500 Received: by mail-pf0-f196.google.com with SMTP id l24so6280918pfj.6; Wed, 15 Nov 2017 20:29:13 -0800 (PST) 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 :in-reply-to:references; bh=6pF6gwfTlKPSTJZDvrlF3yxeY1NYhMav+oF3TopfMzc=; b=mi1K2KTrx8+23GrHTWXzeuC/BE9+oqqP0shqWuVthYKn+YulDW0o3We+LNsGQVaW45 1qBnTcamua2gGTeG/sbCDeBe2xEUeFeCk2FL4FQL89z3jKyl9Jpo6XuT4k0anQe6+8yg AVH0I2iPiHa7uZ/wr/m32ninT8FO4sixUtUz0WfkAyr39QJDQA+SDeLE2pR2waxo0Cl/ jsdXA3nzTOMK47/TGHktquTZ0pqGKCVO6oW+1XzqmxPQTRphGGJlJbfTjEj9fwxDoS6F MwvtQktz0VpT/jPCcXiXbLdKUrtaj4ihpqA62BIlrOTLt35Hi/shLnawo3O7Ax+EbnWk 7TNw== 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:in-reply-to:references; bh=6pF6gwfTlKPSTJZDvrlF3yxeY1NYhMav+oF3TopfMzc=; b=Nm3dhOBsUDNs8MYvtk+hPcrryFqKhaepVOzj1MjKe2LKFWHSzMsytP840oYTmI1Hqs Y4Yn2mnDGcobfEgeWX01PLruyEFeALCdCnkjhs8p6lAtCm1JeyKhxsv2SYaVko+7rkwA x5jyTto3VOx//Ao9BrV5U+TWo7Kebm8vxkcOeEoD/TrKEp0jiIukutHuYHluAikJy5EW cDJSWuYs4dPFmhjwUoULH3J8ek1XdsijDtWsoBIda3U/PcWog+qdWSr60sqKnzjx7RKK UinpFaH9AcbqTjIl2ZfIzOLljc3tUmi5K6KpdvNm5ChfcWxV3M6u7/trlCmMKa1vaAcr mOow== X-Gm-Message-State: AJaThX4/I6QJuz6/n16YhHuTrl5l3S0Qz4MFWMBMiFJLm3NXlq61hlDR klR7q4Jbwp+mkJ4cL4xFhYoK9A== X-Received: by 10.99.120.7 with SMTP id t7mr408773pgc.360.1510806553223; Wed, 15 Nov 2017 20:29:13 -0800 (PST) Received: from symbol-HP-Z420-Workstation.zebra.lan ([223.31.70.102]) by smtp.googlemail.com with ESMTPSA id m69sm421965pfc.27.2017.11.15.20.29.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 15 Nov 2017 20:29:12 -0800 (PST) From: Arvind Yadav To: isdn@linux-pingi.de, davem@davemloft.net, stephen@networkplumber.org, johannes.berg@intel.com Cc: linux-kernel@vger.kernel.org, netdev@vger.kernel.org Subject: [PATCH 08/12] isdn: hisax: Fix pnp_irq's error checking for setup_isurf Date: Thu, 16 Nov 2017 09:57:25 +0530 Message-Id: <68eb2d0c02e1da7f91d522219e32780a7b7996a8.1510805781.git.arvind.yadav.cs@gmail.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The pnp_irq() function returns -1 if an error occurs. pnp_irq() error checking for zero is not correct. Signed-off-by: Arvind Yadav --- drivers/isdn/hisax/isurf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/isdn/hisax/isurf.c b/drivers/isdn/hisax/isurf.c index 1399ddd..53e299b 100644 --- a/drivers/isdn/hisax/isurf.c +++ b/drivers/isdn/hisax/isurf.c @@ -238,7 +238,7 @@ int setup_isurf(struct IsdnCard *card) cs->hw.isurf.reset = pnp_port_start(pnp_d, 0); cs->hw.isurf.phymem = pnp_mem_start(pnp_d, 1); cs->irq = pnp_irq(pnp_d, 0); - if (!cs->irq || !cs->hw.isurf.reset || !cs->hw.isurf.phymem) { + if (cs->irq == -1 || !cs->hw.isurf.reset || !cs->hw.isurf.phymem) { printk(KERN_ERR "ISurfPnP:some resources are missing %d/%x/%lx\n", cs->irq, cs->hw.isurf.reset, cs->hw.isurf.phymem); pnp_disable_dev(pnp_d); -- 1.9.1 From 1584324071630343682@xxx Fri Nov 17 14:32:55 +0000 2017 X-GM-THRID: 1584208143843177959 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread