diff mbox

[2/5] mfd: sunxi-gpadc-mfd: add buffer structure

Message ID 1469003351-15263-3-git-send-email-quentin.schulz@free-electrons.com (mailing list archive)
State New, archived
Headers show

Commit Message

Quentin Schulz July 20, 2016, 8:29 a.m. UTC
This adds a buffer structure for files including the sunxi-gpadc-mfd
header. This structure has a buffer of 32 u32 values to store data from the
FIFO of the GPADC of Allwinner SoCs. A buff_size is provided in case the
buffer is not full.

Signed-off-by: Quentin Schulz <quentin.schulz@free-electrons.com>
---
 include/linux/mfd/sunxi-gpadc-mfd.h | 5 +++++
 1 file changed, 5 insertions(+)

Comments

Jonathan Cameron July 24, 2016, 10:32 a.m. UTC | #1
On 20/07/16 09:29, Quentin Schulz wrote:
> This adds a buffer structure for files including the sunxi-gpadc-mfd
> header. This structure has a buffer of 32 u32 values to store data from the
> FIFO of the GPADC of Allwinner SoCs. A buff_size is provided in case the
> buffer is not full.
> 
> Signed-off-by: Quentin Schulz <quentin.schulz@free-electrons.com>
I'd roll this into the first patch that uses it.
Easier to see what is for when reviewing then!

Jonathan
> ---
>  include/linux/mfd/sunxi-gpadc-mfd.h | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/include/linux/mfd/sunxi-gpadc-mfd.h b/include/linux/mfd/sunxi-gpadc-mfd.h
> index 7155845..f658299 100644
> --- a/include/linux/mfd/sunxi-gpadc-mfd.h
> +++ b/include/linux/mfd/sunxi-gpadc-mfd.h
> @@ -20,4 +20,9 @@ struct sunxi_gpadc_mfd_dev {
>  	void __iomem			*regs;
>  };
>  
> +struct sunxi_gpadc_buffer {
> +	u32				buffer[32];
> +	unsigned int			buff_size;
> +};
> +
>  #endif
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/include/linux/mfd/sunxi-gpadc-mfd.h b/include/linux/mfd/sunxi-gpadc-mfd.h
index 7155845..f658299 100644
--- a/include/linux/mfd/sunxi-gpadc-mfd.h
+++ b/include/linux/mfd/sunxi-gpadc-mfd.h
@@ -20,4 +20,9 @@  struct sunxi_gpadc_mfd_dev {
 	void __iomem			*regs;
 };
 
+struct sunxi_gpadc_buffer {
+	u32				buffer[32];
+	unsigned int			buff_size;
+};
+
 #endif