Add driver-dependent PowerDown
This commit is contained in:
parent
db8033622a
commit
1682a86166
7 changed files with 17 additions and 6 deletions
|
@ -516,6 +516,8 @@ const struct nfc_driver acr122_pcsc_driver = {
|
|||
.device_get_information_about = pn53x_get_information_about,
|
||||
|
||||
.abort_command = NULL, // Abort is not supported in this driver
|
||||
.idle = NULL, // Idle is not supported in this driver
|
||||
.idle = pn53x_idle,
|
||||
/* Even if PN532, PowerDown is not recommended on those devices */
|
||||
.powerdown = NULL,
|
||||
};
|
||||
|
||||
|
|
|
@ -893,5 +893,7 @@ const struct nfc_driver acr122_usb_driver = {
|
|||
.device_get_information_about = pn53x_get_information_about,
|
||||
|
||||
.abort_command = acr122_usb_abort_command,
|
||||
.idle = NULL, // Even with a PN532, PowerDown doesn't seem a good idea here
|
||||
.idle = pn53x_idle,
|
||||
/* Even if PN532, PowerDown is not recommended on those devices */
|
||||
.powerdown = NULL,
|
||||
};
|
||||
|
|
|
@ -726,5 +726,7 @@ const struct nfc_driver acr122s_driver = {
|
|||
.device_get_information_about = pn53x_get_information_about,
|
||||
|
||||
.abort_command = acr122s_abort_command,
|
||||
.idle = NULL,
|
||||
.idle = pn53x_idle,
|
||||
/* Even if PN532, PowerDown is not recommended on those devices */
|
||||
.powerdown = NULL,
|
||||
};
|
||||
|
|
|
@ -587,6 +587,8 @@ const struct nfc_driver arygon_driver = {
|
|||
.device_get_information_about = pn53x_get_information_about,
|
||||
|
||||
.abort_command = arygon_abort_command,
|
||||
.idle = NULL, // FIXME arygon driver does not support idle()
|
||||
.idle = pn53x_idle,
|
||||
/* Even if PN532, PowerDown is not recommended on those devices */
|
||||
.powerdown = NULL,
|
||||
};
|
||||
|
||||
|
|
|
@ -529,5 +529,6 @@ const struct nfc_driver pn532_uart_driver = {
|
|||
|
||||
.abort_command = pn532_uart_abort_command,
|
||||
.idle = pn53x_idle,
|
||||
.powerdown = pn53x_PowerDown,
|
||||
};
|
||||
|
||||
|
|
|
@ -792,4 +792,5 @@ const struct nfc_driver pn53x_usb_driver = {
|
|||
|
||||
.abort_command = pn53x_usb_abort_command,
|
||||
.idle = pn53x_idle,
|
||||
.powerdown = pn53x_PowerDown,
|
||||
};
|
||||
|
|
|
@ -147,6 +147,7 @@ struct nfc_driver {
|
|||
|
||||
int (*abort_command)(struct nfc_device *pnd);
|
||||
int (*idle)(struct nfc_device *pnd);
|
||||
int (*powerdown)(struct nfc_device *pnd);
|
||||
};
|
||||
|
||||
# define DEVICE_NAME_LENGTH 256
|
||||
|
|
Loading…
Add table
Reference in a new issue