Files

47 lines
1.2 KiB
C

/*
* Copyright (c) 202X Amlogic, Inc. All rights reserved.
*
* This source code is subject to the terms and conditions defined in the
* file 'LICENSE' which is part of this source code package.
*
* Description:
*/
#ifndef __RC_LIST_H__
#define __RC_LIST_H__
#define AML_BT_CHAR_RCLIST_NAME "aml_rclist"
#define MAC_ADDR_LEN 6
#define MAX_MAC_LIST 8
#define MAX_USER_BUF_LEN (MAX_MAC_LIST*17+1)
#if defined(CONFIG_AML_BT_CHIP_W1D)
#define FIFO_FW_RC_LIST_ADDR (0xf7403000 + 2364 + 4) //addr 0xf7403940 usb bulk 16 bit alignment
#define FW_RC_LIST_UART_ADDR (0xf7403000 + 2364 + 4)
#else
#define FIFO_FW_RC_LIST_ADDR (0x514000 + 2364 + 4) //addr 0x514940 usb bulk 16 bit alignment
#define FW_RC_LIST_UART_ADDR (0xe14000 + 2364 + 4)
#endif
int amlbt_rc_list_init(struct device *dev);
void amlbt_rc_list_deinit(struct device *dev);
int amlbt_write_rclist_to_firmware(void);
void amlbt_clear_rclist_from_firmware(void);
void amlbt_wakeup_lock(void);
void amlbt_wakeup_unlock(void);
typedef struct _rc_list_t
{
char mac[MAC_ADDR_LEN];
char used;
} rc_list_t;
typedef struct
{
int wake_mux;
struct wakeup_source *amlbt_wakeup_source;
} list_bt_t;
#endif