| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * DS1287 clockevent driver |
|---|
| 3 | 4 | * |
|---|
| 4 | 5 | * Copyright (C) 2008 Yoichi Yuasa <yuasa@linux-mips.org> |
|---|
| 5 | | - * |
|---|
| 6 | | - * This program is free software; you can redistribute it and/or modify |
|---|
| 7 | | - * it under the terms of the GNU General Public License as published by |
|---|
| 8 | | - * the Free Software Foundation; either version 2 of the License, or |
|---|
| 9 | | - * (at your option) any later version. |
|---|
| 10 | | - * |
|---|
| 11 | | - * This program is distributed in the hope that it will be useful, |
|---|
| 12 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 13 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|---|
| 14 | | - * GNU General Public License for more details. |
|---|
| 15 | | - * |
|---|
| 16 | | - * You should have received a copy of the GNU General Public License |
|---|
| 17 | | - * along with this program; if not, write to the Free Software |
|---|
| 18 | | - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
|---|
| 19 | 6 | */ |
|---|
| 20 | 7 | #include <linux/clockchips.h> |
|---|
| 21 | 8 | #include <linux/init.h> |
|---|
| .. | .. |
|---|
| 113 | 100 | return IRQ_HANDLED; |
|---|
| 114 | 101 | } |
|---|
| 115 | 102 | |
|---|
| 116 | | -static struct irqaction ds1287_irqaction = { |
|---|
| 117 | | - .handler = ds1287_interrupt, |
|---|
| 118 | | - .flags = IRQF_PERCPU | IRQF_TIMER, |
|---|
| 119 | | - .name = "ds1287", |
|---|
| 120 | | -}; |
|---|
| 121 | | - |
|---|
| 122 | 103 | int __init ds1287_clockevent_init(int irq) |
|---|
| 123 | 104 | { |
|---|
| 105 | + unsigned long flags = IRQF_PERCPU | IRQF_TIMER; |
|---|
| 124 | 106 | struct clock_event_device *cd; |
|---|
| 125 | 107 | |
|---|
| 126 | 108 | cd = &ds1287_clockevent; |
|---|
| .. | .. |
|---|
| 135 | 117 | |
|---|
| 136 | 118 | clockevents_register_device(&ds1287_clockevent); |
|---|
| 137 | 119 | |
|---|
| 138 | | - return setup_irq(irq, &ds1287_irqaction); |
|---|
| 120 | + return request_irq(irq, ds1287_interrupt, flags, "ds1287", NULL); |
|---|
| 139 | 121 | } |
|---|