hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/drivers/media/rc/ite-cir.h
....@@ -1,17 +1,8 @@
1
+/* SPDX-License-Identifier: GPL-2.0-or-later */
12 /*
23 * Driver for ITE Tech Inc. IT8712F/IT8512F CIR
34 *
45 * Copyright (C) 2010 Juan Jesús García de Soria <skandalfo@gmail.com>
5
- *
6
- * This program is free software; you can redistribute it and/or
7
- * modify it under the terms of the GNU General Public License as
8
- * published by the Free Software Foundation; either version 2 of the
9
- * License, or (at your option) any later version.
10
- *
11
- * This program is distributed in the hope that it will be useful, but
12
- * WITHOUT ANY WARRANTY; without even the implied warranty of
13
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14
- * General Public License for more details.
156 */
167
178 /* platform driver name to register */
....@@ -155,8 +146,8 @@
155146 #define ITE_DEFAULT_CARRIER_FREQ 38000
156147
157148 /* convert bits to us */
158
-#define ITE_BITS_TO_NS(bits, sample_period) \
159
-((u32) ((bits) * ITE_BAUDRATE_DIVISOR * sample_period))
149
+#define ITE_BITS_TO_US(bits, sample_period) \
150
+((u32)((bits) * ITE_BAUDRATE_DIVISOR * (sample_period) / 1000))
160151
161152 /*
162153 * n in RDCR produces a tolerance of +/- n * 6.25% around the center