summaryrefslogtreecommitdiff
path: root/lwis_device_test.h
blob: 40129540de892ee2180a7aef56f4b106d6ca1f4c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
/* SPDX-License-Identifier: GPL-2.0 */
/*
 * Google LWIS Test Device Driver
 *
 * Copyright (c) 2022 Google, LLC
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 as
 * published by the Free Software Foundation.
 */

#ifndef LWIS_DEVICE_TEST_H_
#define LWIS_DEVICE_TEST_H_

#include "lwis_commands.h"
#include "lwis_device.h"

#define SCRATCH_TEST_DEV_MEMORY_SIZE 32

/*
 *  struct lwis_test_device
 *  The device majorly control/handle requests from test clients.
 */
struct lwis_test_device {
	struct lwis_device base_dev;
	/*
	 * For testing purposes, scratch memory is used as register space in
	 * test device.
	 */
	uint8_t scratch_mem[SCRATCH_TEST_DEV_MEMORY_SIZE];
};

int lwis_test_device_deinit(void);

#endif /* LWIS_DEVICE_TEST_H_ */