From 6d0f1c77e52ac06f037d3a80d6a5d8ebbf8b793b Mon Sep 17 00:00:00 2001 From: MacRsh Date: Mon, 11 Dec 2023 18:01:06 +0800 Subject: [PATCH] =?UTF-8?q?1.=E9=80=82=E9=85=8D=E6=A0=87=E5=87=86CONFIG?= =?UTF-8?q?=E5=91=BD=E4=BB=A4=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- device/adc.c | 1 - device/dac.c | 1 - device/pin.c | 3 +-- include/device/pin.h | 2 +- 4 files changed, 2 insertions(+), 5 deletions(-) diff --git a/device/adc.c b/device/adc.c index 67a06db..5cd4562 100644 --- a/device/adc.c +++ b/device/adc.c @@ -101,7 +101,6 @@ static ssize_t mr_adc_read(struct mr_dev *dev, int off, void *buf, size_t size, static int mr_adc_ioctl(struct mr_dev *dev, int off, int cmd, void *args) { struct mr_adc *adc = (struct mr_adc *)dev; - struct mr_adc_ops *ops = (struct mr_adc_ops *)dev->drv->ops; switch (cmd) { diff --git a/device/dac.c b/device/dac.c index c65081c..54c6bb8 100644 --- a/device/dac.c +++ b/device/dac.c @@ -101,7 +101,6 @@ static ssize_t mr_dac_write(struct mr_dev *dev, int off, const void *buf, size_t static int mr_dac_ioctl(struct mr_dev *dev, int off, int cmd, void *args) { struct mr_dac *dac = (struct mr_dac *)dev; - struct mr_dac_ops *ops = (struct mr_dac_ops *)dev->drv->ops; switch (cmd) { diff --git a/device/pin.c b/device/pin.c index d97fe54..a0af438 100644 --- a/device/pin.c +++ b/device/pin.c @@ -118,7 +118,6 @@ static ssize_t mr_pin_write(struct mr_dev *dev, int off, const void *buf, size_t static int mr_pin_ioctl(struct mr_dev *dev, int off, int cmd, void *args) { struct mr_pin *pin = (struct mr_pin *)dev; - struct mr_pin_ops *ops = (struct mr_pin_ops *)dev->drv->ops; switch (cmd) { @@ -156,7 +155,7 @@ static ssize_t mr_pin_isr(struct mr_dev *dev, int event, void *args) switch (event) { - case MR_ISR_PIN_RD_INT: + case MR_ISR_PIN_EXTI_INT: { ssize_t number = *(int *)args; diff --git a/include/device/pin.h b/include/device/pin.h index e65df97..ee9642b 100644 --- a/include/device/pin.h +++ b/include/device/pin.h @@ -70,7 +70,7 @@ typedef uint8_t mr_pin_data_t; /**< PIN rea /** * @brief PIN ISR events. */ -#define MR_ISR_PIN_RD_INT (MR_ISR_RD | (0x01 << 8)) /**< Read interrupt */ +#define MR_ISR_PIN_EXTI_INT (MR_ISR_RD | (0x01 << 8)) /**< Exti interrupt */ /** * @brief PIN structure.