2017-12-01 21:47:13 +08:00
|
|
|
/*
|
|
|
|
* SPDX-License-Identifier: GPL-2.0+
|
|
|
|
*
|
|
|
|
* Siano Mobile Silicon, Inc.
|
|
|
|
* MDTV receiver kernel modules.
|
|
|
|
* Copyright (C) 2006-2009, Uri Shkolnik
|
|
|
|
*
|
|
|
|
* Copyright (c) 2010 - Mauro Carvalho Chehab
|
|
|
|
* - Ported the driver to use rc-core
|
|
|
|
* - IR raw event decoding is now done at rc-core
|
|
|
|
* - Code almost re-written
|
|
|
|
*/
|
2009-04-05 17:01:37 +08:00
|
|
|
|
|
|
|
#ifndef __SMS_IR_H__
|
|
|
|
#define __SMS_IR_H__
|
|
|
|
|
|
|
|
#include <linux/input.h>
|
2010-11-18 00:28:38 +08:00
|
|
|
#include <media/rc-core.h>
|
2009-04-05 17:01:37 +08:00
|
|
|
|
|
|
|
struct smscore_device_t;
|
|
|
|
|
|
|
|
struct ir_t {
|
2010-10-30 03:08:23 +08:00
|
|
|
struct rc_dev *dev;
|
2010-08-02 04:19:29 +08:00
|
|
|
char name[40];
|
2010-08-02 02:30:50 +08:00
|
|
|
char phys[32];
|
2010-08-02 04:19:29 +08:00
|
|
|
|
|
|
|
char *rc_codes;
|
|
|
|
|
2009-04-05 17:01:37 +08:00
|
|
|
u32 timeout;
|
|
|
|
u32 controller;
|
|
|
|
};
|
|
|
|
|
2012-10-18 03:59:01 +08:00
|
|
|
#ifdef CONFIG_SMS_SIANO_RC
|
2009-04-05 17:01:37 +08:00
|
|
|
int sms_ir_init(struct smscore_device_t *coredev);
|
|
|
|
void sms_ir_exit(struct smscore_device_t *coredev);
|
|
|
|
void sms_ir_event(struct smscore_device_t *coredev,
|
|
|
|
const char *buf, int len);
|
2012-10-18 03:59:01 +08:00
|
|
|
#else
|
|
|
|
inline static int sms_ir_init(struct smscore_device_t *coredev) {
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
inline static void sms_ir_exit(struct smscore_device_t *coredev) {};
|
|
|
|
inline static void sms_ir_event(struct smscore_device_t *coredev,
|
|
|
|
const char *buf, int len) {};
|
|
|
|
#endif
|
2009-04-05 17:01:37 +08:00
|
|
|
|
|
|
|
#endif /* __SMS_IR_H__ */
|
|
|
|
|