diff options
author | Harry Hong <hhong@nvidia.com> | 2013-08-26 14:53:01 +0900 |
---|---|---|
committer | Gabby Lee <galee@nvidia.com> | 2013-08-27 19:42:46 -0700 |
commit | a69c29fc91cf581fdd678fa05a6b33568ef9ccc7 (patch) | |
tree | a0e9f07a6c01c5934b4e4f9e567c41a375b3478a /drivers | |
parent | 2d6b66dda6650ba55ebc6cb8bed55891be41c29e (diff) |
misc: ti-st: Adding IORESOURCE_IRQ_OPTIONAL case
if flag is IORESOURCE_IRQ_OPTIONAL, don't request irq
because this irq need to be registered in another driver.
bug 1347948
Change-Id: I3178aca5b09421b5f6c53d28b6327f530d405e9c
Signed-off-by: Harry Hong <hhong@nvidia.com>
Reviewed-on: http://git-master/r/265925
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Gabby Lee <galee@nvidia.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/misc/ti-st/st_host_wake.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/drivers/misc/ti-st/st_host_wake.c b/drivers/misc/ti-st/st_host_wake.c index c47450ba9a49..5f03d405d933 100644 --- a/drivers/misc/ti-st/st_host_wake.c +++ b/drivers/misc/ti-st/st_host_wake.c @@ -2,6 +2,7 @@ * Shared Transport Host wake up driver * For protocols registered over Shared Transport * Copyright (C) 2011-2012 Texas Instruments + * Copyright (c) 2013, NVIDIA CORPORATION. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as @@ -176,15 +177,16 @@ static int st_host_wake_probe(struct platform_device *pdev) goto free_bsi; } - if (res->flags & IORESOURCE_IRQ_LOWEDGE) - ret = request_irq(bsi->host_wake_irq, st_host_wake_isr, - IRQF_DISABLED | IRQF_TRIGGER_FALLING, - "bluetooth hostwake", dev_id); - else - ret = request_irq(bsi->host_wake_irq, st_host_wake_isr, - IRQF_DISABLED | IRQF_TRIGGER_RISING, - "bluetooth hostwake", dev_id); - + if (!(res->flags & IORESOURCE_IRQ_OPTIONAL)) { + if (res->flags & IORESOURCE_IRQ_LOWEDGE) + ret = request_irq(bsi->host_wake_irq, st_host_wake_isr, + IRQF_DISABLED | IRQF_TRIGGER_FALLING, + "bluetooth hostwake", dev_id); + else + ret = request_irq(bsi->host_wake_irq, st_host_wake_isr, + IRQF_DISABLED | IRQF_TRIGGER_RISING, + "bluetooth hostwake", dev_id); + } if (ret < 0) { pr_err("Couldn't acquire HOST_WAKE IRQ"); goto free_bsi; |