lkml.org 
[lkml]   [2005]   [Jul]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[PATCH 2.6.13-rc3 3/6] failure of acpi_register_gsi() should be handled properly - change hpet driver

    This patch adds the error check of acpi_register_gsi() into hpet
    driver.

    Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>


    ---

    linux-2.6.13-rc3-kanesige/drivers/char/hpet.c | 8 ++++++--
    1 files changed, 6 insertions(+), 2 deletions(-)

    diff -puN drivers/char/hpet.c~handle-error-acpi_register_gsi-hpet drivers/char/hpet.c
    --- linux-2.6.13-rc3/drivers/char/hpet.c~handle-error-acpi_register_gsi-hpet 2005-07-28 01:01:16.000000000 +0900
    +++ linux-2.6.13-rc3-kanesige/drivers/char/hpet.c 2005-07-28 01:01:16.000000000 +0900
    @@ -906,11 +906,15 @@ static acpi_status hpet_resources(struct
    if (irqp->number_of_interrupts > 0) {
    hdp->hd_nirqs = irqp->number_of_interrupts;

    - for (i = 0; i < hdp->hd_nirqs; i++)
    - hdp->hd_irq[i] =
    + for (i = 0; i < hdp->hd_nirqs; i++) {
    + int rc =
    acpi_register_gsi(irqp->interrupts[i],
    irqp->edge_level,
    irqp->active_high_low);
    + if (rc < 0)
    + return AE_ERROR;
    + hdp->hd_irq[i] = rc;
    + }
    }
    }

    _

    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-07-28 10:00    [W:0.048 / U:31.664 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site