mirror of
https://github.com/apache/nuttx.git
synced 2026-06-06 16:50:55 +08:00
drivers/input: Rename AJOYSTICK configs to INPUT_AJOYSTICK
This commit is contained in:
committed by
Alan Carvalho de Assis
parent
3054237d2e
commit
ada84cacda
@@ -490,7 +490,7 @@ config INPUT_DJOYSTICK_NPOLLWAITERS
|
||||
|
||||
endif # INPUT_DJOYSTICK
|
||||
|
||||
config AJOYSTICK
|
||||
config INPUT_AJOYSTICK
|
||||
bool "Analog Joystick"
|
||||
default n
|
||||
---help---
|
||||
@@ -500,13 +500,13 @@ config AJOYSTICK
|
||||
to-Digital Conversion (ADC). The analog positional data may also
|
||||
be accompanied by discrete button data.
|
||||
|
||||
if AJOYSTICK
|
||||
if INPUT_AJOYSTICK
|
||||
|
||||
config AJOYSTICK_NPOLLWAITERS
|
||||
config INPUT_AJOYSTICK_NPOLLWAITERS
|
||||
int "Max Number of Poll Waiters"
|
||||
default 2
|
||||
|
||||
endif # AJOYSTICK
|
||||
endif # INPUT_AJOYSTICK
|
||||
|
||||
config INPUT_NUNCHUCK
|
||||
bool "Nintendo Wii Nunchuck Joystick (White Model)"
|
||||
|
||||
@@ -76,7 +76,7 @@ ifeq ($(CONFIG_INPUT_DJOYSTICK),y)
|
||||
CSRCS += djoystick.c
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_AJOYSTICK),y)
|
||||
ifeq ($(CONFIG_INPUT_AJOYSTICK),y)
|
||||
CSRCS += ajoystick.c
|
||||
endif
|
||||
|
||||
|
||||
@@ -99,7 +99,7 @@ struct ajoy_open_s
|
||||
* driver events.
|
||||
*/
|
||||
|
||||
FAR struct pollfd *ao_fds[CONFIG_AJOYSTICK_NPOLLWAITERS];
|
||||
FAR struct pollfd *ao_fds[CONFIG_INPUT_AJOYSTICK_NPOLLWAITERS];
|
||||
};
|
||||
|
||||
/****************************************************************************
|
||||
@@ -192,7 +192,7 @@ static void ajoy_enable(FAR struct ajoy_upperhalf_s *priv)
|
||||
{
|
||||
/* Are there any poll waiters? */
|
||||
|
||||
for (i = 0; i < CONFIG_AJOYSTICK_NPOLLWAITERS; i++)
|
||||
for (i = 0; i < CONFIG_INPUT_AJOYSTICK_NPOLLWAITERS; i++)
|
||||
{
|
||||
if (opriv->ao_fds[i])
|
||||
{
|
||||
@@ -299,7 +299,7 @@ static void ajoy_sample(FAR struct ajoy_upperhalf_s *priv)
|
||||
{
|
||||
/* Yes.. Notify all waiters */
|
||||
|
||||
for (i = 0; i < CONFIG_AJOYSTICK_NPOLLWAITERS; i++)
|
||||
for (i = 0; i < CONFIG_INPUT_AJOYSTICK_NPOLLWAITERS; i++)
|
||||
{
|
||||
FAR struct pollfd *fds = opriv->ao_fds[i];
|
||||
if (fds)
|
||||
@@ -708,7 +708,7 @@ static int ajoy_poll(FAR struct file *filep, FAR struct pollfd *fds,
|
||||
* slot for the poll structure reference
|
||||
*/
|
||||
|
||||
for (i = 0; i < CONFIG_AJOYSTICK_NPOLLWAITERS; i++)
|
||||
for (i = 0; i < CONFIG_INPUT_AJOYSTICK_NPOLLWAITERS; i++)
|
||||
{
|
||||
/* Find an available slot */
|
||||
|
||||
@@ -722,7 +722,7 @@ static int ajoy_poll(FAR struct file *filep, FAR struct pollfd *fds,
|
||||
}
|
||||
}
|
||||
|
||||
if (i >= CONFIG_AJOYSTICK_NPOLLWAITERS)
|
||||
if (i >= CONFIG_INPUT_AJOYSTICK_NPOLLWAITERS)
|
||||
{
|
||||
ierr("ERROR: Too man poll waiters\n");
|
||||
fds->priv = NULL;
|
||||
|
||||
Reference in New Issue
Block a user