| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * IR SIR driver, (C) 2000 Milan Pikula <www@fornax.sk> |
|---|
| 3 | 4 | * |
|---|
| 4 | 5 | * sir_ir - Device driver for use with SIR (serial infra red) |
|---|
| 5 | 6 | * mode of IrDA on many notebooks. |
|---|
| 6 | | - * |
|---|
| 7 | | - * This program is free software; you can redistribute it and/or modify |
|---|
| 8 | | - * it under the terms of the GNU General Public License as published by |
|---|
| 9 | | - * the Free Software Foundation; either version 2 of the License, or |
|---|
| 10 | | - * (at your option) any later version. |
|---|
| 11 | 7 | */ |
|---|
| 12 | 8 | |
|---|
| 13 | 9 | #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt |
|---|
| .. | .. |
|---|
| 96 | 92 | |
|---|
| 97 | 93 | static void add_read_queue(int flag, unsigned long val) |
|---|
| 98 | 94 | { |
|---|
| 99 | | - DEFINE_IR_RAW_EVENT(ev); |
|---|
| 95 | + struct ir_raw_event ev = {}; |
|---|
| 100 | 96 | |
|---|
| 101 | 97 | pr_debug("add flag %d with val %lu\n", flag, val); |
|---|
| 102 | 98 | |
|---|
| .. | .. |
|---|
| 114 | 110 | } else { |
|---|
| 115 | 111 | val += TIME_CONST / 2; |
|---|
| 116 | 112 | } |
|---|
| 117 | | - ev.duration = US_TO_NS(val); |
|---|
| 113 | + ev.duration = val; |
|---|
| 118 | 114 | |
|---|
| 119 | 115 | ir_raw_event_store_with_filter(rcdev, &ev); |
|---|
| 120 | 116 | } |
|---|