mfd: Add Renesas R-Car Gen3 RPC-IF MFD & SPI driver
Subsystems (3)
v10 cover mfd: Add Renesas R-Car Gen3 RPC-IF MFD & SPI driver
Hi,
v10 patch including:
1) Address range for > 64M byte flash.
2) Removed dirmap_write due to WBUF 256 bytes transfer issue.
3) Dummy bytes setting according to spi-nor.c layer.
v9 patch is for RPC MFD driver and RPC SPI driver.
v8 patch including:
1) Supported SoC-specific values in DTS.
2) Rename device node name as flash.
v7 patch is according to Geert and Sergei's comments:
1) Add all R-Car Gen3 model in dts.
2) patch rpc-if child node search.
3) minror coding style.
v6 patch is accroding to Geert, Marek and Sergei's comments:
1) spi_controller for new code.
2) "renesas,rcar-gen3-rpc" instead of "renesas,r8a77995-rpc."
3) patch external address read mode w/o u64 readq().
4) patch dts for write buffer & drop "renesas,rpc-mode".
5) coding style and so on.
v5 patch is accroding to Sergei's comments:
1) Read 6 bytes ID from Sergei's patch.
2) regmap_update_bits().
3) C++ style comment.
v4 patch is according to Sergei's comments including:
1) Drop soc_device_match().
2) Drop unused RPC registers.
3) Use ilog2() instead of fls().
4) Patch read 6 bytes ID w/ one command.
5) Coding style and so on.
v3 patch is according to Marek and Geert's comments including:
1) soc_device_mach() to set up RPC_PHYCNT_STRTIM.
2) get_unaligned().
3) rpc-mode for rpi-spi-flash or rpc-hyperflash.
4) coding style and so on.
v2 patch including:
1) remove RPC clock enable/dis-able control,
2) patch run time PM.
3) add RPC module software reset,
4) add regmap.
5) other coding style and so on.
thanks for your review.
best regards,
Mason
Mason Yang (3):
mfd: Add Renesas R-Car Gen3 RPC-IF MFD controller driver
spi: Add Renesas R-Car Gen3 RPC-IF SPI controller driver
dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller
bindings
.../devicetree/bindings/mfd/mfd-renesas-rpc.txt | 37 ++ drivers/mfd/Kconfig | 9 + drivers/mfd/Makefile | 1 + drivers/mfd/renesas-rpc.c | 128 +++++ drivers/spi/Kconfig | 6 + drivers/spi/Makefile | 1 + drivers/spi/spi-renesas-rpc.c | 561 +++++++++++++++++++++ include/linux/mfd/renesas-rpc.h | 153 ++++++ 8 files changed, 896 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt create mode 100644 drivers/mfd/renesas-rpc.c create mode 100644 drivers/spi/spi-renesas-rpc.c create mode 100644 include/linux/mfd/renesas-rpc.h
Signature · 1 line
1.9.1
PATCH v10 1/3 mfd: Add Renesas R-Car Gen3 RPC-IF MFD controller driver
Add a driver for Renesas R-Car Gen3 RPC-IF MFD controller.
--- drivers/mfd/Kconfig | 9 +++ drivers/mfd/Makefile | 1 + drivers/mfd/renesas-rpc.c | 128 +++++++++++++++++++++++++++++++++ include/linux/mfd/renesas-rpc.h | 153 ++++++++++++++++++++++++++++++++++++++++ 4 files changed, 291 insertions(+) create mode 100644 drivers/mfd/renesas-rpc.c create mode 100644 include/linux/mfd/renesas-rpc.h
drivers/mfd/Kconfig +9 -0
@@ -978,6 +978,15 @@ config MFD_RDC321X southbridge which provides access to GPIOs and Watchdog using the southbridge PCI device configuration space. +config MFD_RENESAS_RPC + tristate "Renesas R-Car Gen3 RPC-IF MFD driver" + select MFD_CORE + depends on ARCH_RENESAS + help + This supports for Renesas R-Car Gen3 RPC-IF multifunction device + controller which provides either SPI host controller or HyperFlash. + You have to select individual components under the corresponding menu. + config MFD_RT5033 tristate "Richtek RT5033 Power Management IC" depends on I2C
drivers/mfd/Makefile +1 -0
@@ -183,6 +183,7 @@ obj-$(CONFIG_MFD_INTEL_QUARK_I2C_GPIO) += intel_quark_i2c_gpio.o obj-$(CONFIG_LPC_SCH) += lpc_sch.o obj-$(CONFIG_LPC_ICH) += lpc_ich.o obj-$(CONFIG_MFD_RDC321X) += rdc321x-southbridge.o +obj-$(CONFIG_MFD_RENESAS_RPC) += renesas-rpc.o obj-$(CONFIG_MFD_JANZ_CMODIO) += janz-cmodio.o obj-$(CONFIG_MFD_JZ4740_ADC) += jz4740-adc.o obj-$(CONFIG_MFD_TPS6586X) += tps6586x.o
drivers/mfd/renesas-rpc.c new file +128 -0
128 lines not on this page · raw message
include/linux/mfd/renesas-rpc.h new file +153 -0
153 lines not on this page · raw message
Signature · 1 line
1.9.1
Re: [PATCH v10 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD controller driver
The patch name is somewhat misleading -- there's no "MFD controller".
Quoted 3 lines · Mason Yang
Add a driver for Renesas R-Car Gen3 RPC-IF MFD controller.
Signed-off-by Mason Yang <[email protected]>
[...]
Quoted 5 lines
drivers/mfd/Kconfig +0
-0
drivers/mfd/Kconfig config MFD_RDC321X · line 986
Quoted 9 lines
drivers/mfd/Kconfig +6
-0@@ -978,6 +978,15 @@ config MFD_RDC321X southbridge which provides access to GPIOs and Watchdog using the southbridge PCI device configuration space. +config MFD_RENESAS_RPC + tristate "Renesas R-Car Gen3 RPC-IF MFD driver" + select MFD_CORE + depends on ARCH_RENESAS + help + This supports for Renesas R-Car Gen3 RPC-IF multifunction device
"For" node needed here.
Quoted 6 lines
drivers/mfd/Kconfig +3
-0+ controller which provides either SPI host controller or HyperFlash. + You have to select individual components under the corresponding menu. + config MFD_RT5033 tristate "Richtek RT5033 Power Management IC" depends on I2C
[...]
Quoted 13 lines
drivers/mfd/renesas-rpc.c new file +7
-0@@ -0,0 +1,128 @@ +// SPDX-License-Identifier: GPL-2.0 +// +// Copyright (C) 2018 ~ 2019 Renesas Solutions Corp. +// Copyright (C) 2019 Macronix International Co., Ltd. +// +// R-Car Gen3 RPC-IF MFD driver +//
drivers/mfd/renesas-rpc.c line 17
Quoted 10 lines
drivers/mfd/renesas-rpc.c new file +10
-0+// Author: +// Mason Yang <[email protected]> +// + +#include <linux/mfd/renesas-rpc.h> +#include <linux/mfd/core.h> + +static const struct mfd_cell rpc_hf_ctlr = { + .name ="rpc-hf" , + .of_compatible ="renesas,rcar-rpc-hf" ,
Don't need this line any more...
drivers/mfd/renesas-rpc.c line 22
Quoted 5 lines
drivers/mfd/renesas-rpc.c new file +5
-0+}; + +static const struct mfd_cell rpc_spi_ctlr = { + .name ="rpc-spi" , + .of_compatible ="renesas,rcar-rpc-spi" ,
... and this too.
[...]
Quoted 17 lines
drivers/mfd/renesas-rpc.c new file +17
-0+static int rpc_mfd_probe (struct platform_device *pdev) +{ +struct device_node *flash; +const struct mfd_cell *cell; +struct resource *res; +struct rpc_mfd *rpc; +void __iomem *base; +int ret; + + flash =of_get_next_child (pdev->dev.of_node,NULL ); +if (!flash) { +dev_warn (&pdev->dev,"no flash node found\n" ); +return -ENODEV ; + } + + ret =of_device_is_compatible (flash,"jedec,spi-nor" ); +if (ret) {
drivers/mfd/renesas-rpc.c line 71
Quoted 10 lines
drivers/mfd/renesas-rpc.c new file +10
-0+ cell = &rpc_spi_ctlr; + }else { + ret =of_device_is_compatible (flash,"cfi-flash" ); +if (ret) { + cell = &rpc_hf_ctlr; + }else { +dev_warn (&pdev->dev,"no jedec spi/cfi device found\n" ); +return -ENODEV ; + } + }
This definitely should look simpler, like below:
if (of_device_is_compatible(flash, "jedec,spi-nor")) {
cell = &rpc_spi_ctlr;
} else if (of_device_is_compatible(flash, "cfi-flash")) {
cell = &rpc_hf_ctlr;
} else {
dev_warn(&pdev->dev, "unknown flash type\n");
return -ENODEV;
}[...]
drivers/mfd/renesas-rpc.c line 108
Quoted 3 lines
drivers/mfd/renesas-rpc.c new file +3
-0+ ret =devm_mfd_add_devices (&pdev->dev,-1 , cell,1 ,NULL ,0 ,NULL ); + +return ret;
return devm_mfd_add_devices(&pdev->dev, -1, cell, 1, NULL, 0, NULL);
[...]
Quoted 21 lines
include/linux/mfd/renesas-rpc.h new file +15
-0@@ -0,0 +1,153 @@ +// SPDX-License-Identifier: GPL-2.0 +// +// Copyright (C) 2018 ~ 2019 Renesas Solutions Corp. +// Copyright (C) 2019 Macronix International Co., Ltd. +// +// R-Car Gen3 RPC-IF MFD driver +// +// Author: +// Mason Yang <[email protected]> +// + +#ifndef __MFD_RENESAS_RPC_H +#define __MFD_RENESAS_RPC_H + +#include <linux/clk.h>
include/linux/mfd/renesas-rpc.h line 25
Quoted 10 lines
include/linux/mfd/renesas-rpc.h new file +10
-0+#include <linux/io.h> +#include <linux/log2.h> +#include <linux/iopoll.h> +#include <linux/module.h> +#include <linux/mtd/mtd.h> +#include <linux/platform_device.h> +#include <linux/pm_runtime.h> +#include <linux/of.h> +#include <linux/regmap.h> +#include <linux/reset.h>
NAK. I have already told you that these #include's are only needed in the
drivers, not in this header.
My idea is to contain all hardware manipulation in the MFD driver,
with SPI/HF drivers calling that code via a set of APIs declared in this header. The registers (declared below) would end up only needed by that common MFD driver...
[...]
MBR, Sergei
Re: [PATCH v10 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD controller driver
Hello,
Quoted 1 line
Re: [PATCH v10 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD controller
driver
Quoted 2 lines
The patch name is somewhat misleading -- there's no "MFD controller".
Can't get your point ?
RPC-IF support SPI and HF, it's a MFD controller and that's why I patch it to MFD as Marek's comments.
Quoted 13 lines · Mason Yang
Quoted 4 lines
Add a driver for Renesas R-Car Gen3 RPC-IF MFD controller.
Signed-off-by Mason Yang <[email protected]>[...]
drivers/mfd/Kconfig config MFD_RDC321X · line 978
Quoted 6 lines
drivers/mfd/Kconfig +0
-0@@ -978,6 +978,15 @@ config MFD_RDC321X southbridge which provides access to GPIOs and Watchdog using
the
Quoted 10 lines
drivers/mfd/Kconfig config MFD_RDC321X · line 986
Quoted 8 lines
drivers/mfd/Kconfig +6
-0southbridge PCI device configuration space. +config MFD_RENESAS_RPC + tristate "Renesas R-Car Gen3 RPC-IF MFD driver" + select MFD_CORE + depends on ARCH_RENESAS + help + This supports for Renesas R-Car Gen3 RPC-IF multifunction device"For" node needed here.
?
Quoted 2 lines
drivers/mfd/Kconfig config MFD_RDC321X · line 987
Quoted 2 lines
drivers/mfd/Kconfig +1
-0+ controller which provides either SPI host controller or
HyperFlash.
Quoted 1 line
drivers/mfd/Kconfig config MFD_RDC321X · line 988
Quoted 1 line
drivers/mfd/Kconfig +1
-0+ You have to select individual components under the corresponding
menu.
Quoted 32 lines
Quoted 4 lines
drivers/mfd/Kconfig +1
-0+ config MFD_RT5033 tristate "Richtek RT5033 Power Management IC" depends on I2C[...]
include/linux/mfd/
Quoted 1 line
include/linux/mfd/ renamed from include/linux/mfd/renesas-rpc.h +0
-0
renesas-rpc.hQuoted 24 lines
new file mode 100644
index 0000000..61ada14include/linux/mfd/renesas-rpc.h new file +19
-0@@ -0,0 +1,153 @@ +// SPDX-License-Identifier: GPL-2.0 +// +// Copyright (C) 2018 ~ 2019 Renesas Solutions Corp. +// Copyright (C) 2019 Macronix International Co., Ltd. +// +// R-Car Gen3 RPC-IF MFD driver +// +// Author: +// Mason Yang <[email protected]> +// + +#ifndef __MFD_RENESAS_RPC_H +#define __MFD_RENESAS_RPC_H + +#include <linux/clk.h> +#include <linux/io.h> +#include <linux/log2.h> +#include <linux/iopoll.h> +#include <linux/module.h>
Quoted 8 lines
include/linux/mfd/renesas-rpc.h line 25
Quoted 6 lines
include/linux/mfd/renesas-rpc.h new file +6
-0+#include <linux/mtd/mtd.h> +#include <linux/platform_device.h> +#include <linux/pm_runtime.h> +#include <linux/of.h> +#include <linux/regmap.h> +#include <linux/reset.h> NAK. I have already told you that these #include's are only needed in
the
Quoted 1 line
drivers, not in this header.
why ?
I think these #include files are still needed in HyperFlash driver. i.e,. clk controller, mtd and so on.
Quoted 6 lines
My idea is to contain all hardware manipulation in the MFD driver,
with SPI/HF drivers calling that code via a set of APIs declared in this header.
The registers (declared below) would end up only needed by that common MFD driver...
best regards,
Mason
CONFIDENTIALITY NOTE:
This e-mail and any attachments may contain confidential information and/or personal data, which is protected by applicable laws. Please be reminded that duplication, disclosure, distribution, or use of this e-mail (and/or its attachments) or any part thereof is prohibited. If you receive this e-mail in error, please notify us immediately and delete this mail as well as its attachment(s) from your system. In addition, please be informed that collection, processing, and/or use of personal data is prohibited unless expressly permitted by personal data protection laws. Thank you for your attention and cooperation.
Macronix International Co., Ltd.
=====================================================================
============================================================================
CONFIDENTIALITY NOTE:
This e-mail and any attachments may contain confidential information and/or personal data, which is protected by applicable laws. Please be reminded that duplication, disclosure, distribution, or use of this e-mail (and/or its attachments) or any part thereof is prohibited. If you receive this e-mail in error, please notify us immediately and delete this mail as well as its attachment(s) from your system. In addition, please be informed that collection, processing, and/or use of personal data is prohibited unless expressly permitted by personal data protection laws. Thank you for your attention and cooperation.
Macronix International Co., Ltd.
=====================================================================
Re: [PATCH v10 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD controller driver
Quoted 8 lines · On 04/16/2019 04:19 AM, [email protected] wrote:
Quoted 3 lines
Re: [PATCH v10 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD controller driver
The patch name is somewhat misleading -- there's no "MFD controller".
Can't get your point ?
RPC-IF support SPI and HF, it's a MFD controller and that's why I patch it to MFD as Marek's comments.
I'd like the "controller" word dropped, as MFD stands for multi-function device
anyway. "Controller" seems to be superfluous here...
Quoted 23 lines
Quoted 14 lines · Mason Yang
Quoted 4 lines
Add a driver for Renesas R-Car Gen3 RPC-IF MFD controller.
Signed-off-by Mason Yang <[email protected]>[...]
Quoted 8 lines
drivers/mfd/Kconfig +0
-0@@ -978,6 +978,15 @@ config MFD_RDC321X southbridge which provides access to GPIOs and Watchdog using the southbridge PCI device configuration space.Quoted 8 lines
drivers/mfd/Kconfig config MFD_RDC321X · line 986
Quoted 6 lines
drivers/mfd/Kconfig +6
-0+config MFD_RENESAS_RPC + tristate "Renesas R-Car Gen3 RPC-IF MFD driver" + select MFD_CORE + depends on ARCH_RENESAS + help + This supports for Renesas R-Car Gen3 RPC-IF multifunction device"For" node needed here.
Quoted 1 line
?
Sorry, that was a typo: s/node/not/.
Quoted 37 lines
Quoted 28 lines
[...]
include/linux/mfd/
Quoted 1 line
include/linux/mfd/ renamed from include/linux/mfd/renesas-rpc.h +0
-0
renesas-rpc.hQuoted 25 lines
new file mode 100644
index 0000000..61ada14include/linux/mfd/renesas-rpc.h new file +20
-0@@ -0,0 +1,153 @@ +// SPDX-License-Identifier: GPL-2.0 +// +// Copyright (C) 2018 ~ 2019 Renesas Solutions Corp. +// Copyright (C) 2019 Macronix International Co., Ltd. +// +// R-Car Gen3 RPC-IF MFD driver +// +// Author: +// Mason Yang <[email protected]> +// + +#ifndef __MFD_RENESAS_RPC_H +#define __MFD_RENESAS_RPC_H + +#include <linux/clk.h> +#include <linux/io.h> +#include <linux/log2.h> +#include <linux/iopoll.h> +#include <linux/module.h> +#include <linux/mtd/mtd.h> Quoted 8 lines
include/linux/mfd/renesas-rpc.h line 25
Quoted 5 lines
include/linux/mfd/renesas-rpc.h new file +5
-0+#include <linux/platform_device.h> +#include <linux/pm_runtime.h> +#include <linux/of.h> +#include <linux/regmap.h> +#include <linux/reset.h> NAK. I have already told you that these #include's are only needed in the
drivers, not in this header.
Quoted 1 line
why ?
Why what? As a rule of thumb, we #include only headers necessary to build
the file in question.
Quoted 1 line
I think these #include files are still needed in HyperFlash driver.
Hopefully not. Though that doesn't really matter much.
Quoted 11 lines
i.e,. clk controller, mtd and so on.
Quoted 6 lines
My idea is to contain all hardware manipulation in the MFD driver,
with SPI/HF drivers calling that code via a set of APIs declared in this header.
The registers (declared below) would end up only needed by that common MFD driver...best regards,
Mason
MBR, Sergei
Re: [PATCH v10 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD controller driver
Hello,
Quoted 2 lines
Re: [PATCH v10 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD controller
driver
Quoted 8 lines · On 04/16/2019 04:19 AM, [email protected] wrote:
Quoted 2 lines
Quoted 2 lines
Re: [PATCH v10 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD
controller driver
Quoted 3 lines
Quoted 2 lines
The patch name is somewhat misleading -- there's no "MFD controller".
Quoted 8 lines
Quoted 4 lines
Can't get your point ?
RPC-IF support SPI and HF, it's a MFD controller and that's why I patch it to MFD as Marek's comments.
I'd like the "controller" word dropped, as MFD stands for multi-
function device
anyway. "Controller" seems to be superfluous here...
okay, will rename to:
[PATCH v11 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD driver
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines · Mason Yang
Quoted 3 lines
Add a driver for Renesas R-Car Gen3 RPC-IF MFD controller.
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 1 line
Signed-off-by Mason Yang <[email protected]>[...]
drivers/mfd/Kconfig config MFD_RDC321X · line 978
Quoted 6 lines
drivers/mfd/Kconfig +0
-0@@ -978,6 +978,15 @@ config MFD_RDC321X southbridge which provides access to GPIOs and Watchdog using
the
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
drivers/mfd/Kconfig config MFD_RDC321X
Quoted 8 lines
drivers/mfd/Kconfig +6
-0southbridge PCI device configuration space. +config MFD_RENESAS_RPC + tristate "Renesas R-Car Gen3 RPC-IF MFD driver" + select MFD_CORE + depends on ARCH_RENESAS + help + This supports for Renesas R-Car Gen3 RPC-IF multifunction
device
Quoted 6 lines
Quoted 4 lines
Quoted 2 lines
"For" node needed here.
?
Sorry, that was a typo: s/node/not/.
Oops, still don't know what do you mean to ?
Will change to:
help
This supports for Renesas R-Car Gen3 RPC-IF multifunction
device
which provides either SPI host or HyperFlash. You have to select individual components under the
corresponding menu.
is it ok ?
Quoted 36 lines
Quoted 28 lines
Quoted 28 lines
[...]
include/linux/mfd/
Quoted 1 line
include/linux/mfd/ renamed from include/linux/mfd/renesas-rpc.h +0
-0
renesas-rpc.hQuoted 24 lines
new file mode 100644
index 0000000..61ada14include/linux/mfd/renesas-rpc.h new file +19
-0@@ -0,0 +1,153 @@ +// SPDX-License-Identifier: GPL-2.0 +// +// Copyright (C) 2018 ~ 2019 Renesas Solutions Corp. +// Copyright (C) 2019 Macronix International Co., Ltd. +// +// R-Car Gen3 RPC-IF MFD driver +// +// Author: +// Mason Yang <[email protected]> +// + +#ifndef __MFD_RENESAS_RPC_H +#define __MFD_RENESAS_RPC_H + +#include <linux/clk.h> +#include <linux/io.h> +#include <linux/log2.h> +#include <linux/iopoll.h> +#include <linux/module.h> Quoted 8 lines
Quoted 8 lines
include/linux/mfd/renesas-rpc.h line 25
Quoted 6 lines
include/linux/mfd/renesas-rpc.h new file +6
-0+#include <linux/mtd/mtd.h> +#include <linux/platform_device.h> +#include <linux/pm_runtime.h> +#include <linux/of.h> +#include <linux/regmap.h> +#include <linux/reset.h> NAK. I have already told you that these #include's are only
Quoted 6 lines
needed in the
Quoted 3 lines
Quoted 1 line
drivers, not in this header.
why ?
Why what? As a rule of thumb, we #include only headers necessary to
build
Quoted 1 line
the file in question.
okay, got your point.
thanks & best regards,
Mason
CONFIDENTIALITY NOTE:
This e-mail and any attachments may contain confidential information and/or personal data, which is protected by applicable laws. Please be reminded that duplication, disclosure, distribution, or use of this e-mail (and/or its attachments) or any part thereof is prohibited. If you receive this e-mail in error, please notify us immediately and delete this mail as well as its attachment(s) from your system. In addition, please be informed that collection, processing, and/or use of personal data is prohibited unless expressly permitted by personal data protection laws. Thank you for your attention and cooperation.
Macronix International Co., Ltd.
=====================================================================
============================================================================
CONFIDENTIALITY NOTE:
This e-mail and any attachments may contain confidential information and/or personal data, which is protected by applicable laws. Please be reminded that duplication, disclosure, distribution, or use of this e-mail (and/or its attachments) or any part thereof is prohibited. If you receive this e-mail in error, please notify us immediately and delete this mail as well as its attachment(s) from your system. In addition, please be informed that collection, processing, and/or use of personal data is prohibited unless expressly permitted by personal data protection laws. Thank you for your attention and cooperation.
Macronix International Co., Ltd.
=====================================================================
Re: [PATCH v10 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD controller driver
Quoted 10 lines · On 04/17/2019 09:21 AM, [email protected] wrote:
Quoted 10 lines
Quoted 1 line
Quoted 1 line
Re: [PATCH v10 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD
controller driver
Quoted 7 lines
Quoted 2 lines
The patch name is somewhat misleading -- there's no "MFD controller".
Can't get your point ?
RPC-IF support SPI and HF, it's a MFD controller and that's why I patch it to MFD as Marek's comments.
Quoted 7 lines
Quoted 3 lines
I'd like the "controller" word dropped, as MFD stands for multi-
function device
anyway. "Controller" seems to be superfluous here...okay, will rename to:
[PATCH v11 1/3] mfd: Add Renesas R-Car Gen3 RPC-IF MFD driver
Thanx!
Quoted 29 lines
Quoted 23 lines
Quoted 23 lines
Quoted 22 lines · Mason Yang
Quoted 4 lines
Add a driver for Renesas R-Car Gen3 RPC-IF MFD controller.
Signed-off-by Mason Yang <[email protected]>[...]
Quoted 5 lines
drivers/mfd/Kconfig +0
-0drivers/mfd/Kconfig config MFD_RDC321X · line 986
Quoted 9 lines
drivers/mfd/Kconfig +6
-0@@ -978,6 +978,15 @@ config MFD_RDC321X southbridge which provides access to GPIOs and Watchdog using the southbridge PCI device configuration space. +config MFD_RENESAS_RPC + tristate "Renesas R-Car Gen3 RPC-IF MFD driver" + select MFD_CORE + depends on ARCH_RENESAS + help + This supports for Renesas R-Car Gen3 RPC-IF multifunction device"For" node needed here.
Quoted 3 lines
Quoted 1 line
?
Sorry, that was a typo: s/node/not/.
Oops, still don't know what do you mean to ?
Quoted 7 lines
Will change to:
help
This supports for Renesas R-Car Gen3 RPC-IF multifunction device which provides either SPI host or HyperFlash.
You have to select individual components under the corresponding menu.is it ok ?
Should be "This supports Renesas..."
[...]
MBR, Sergei
PATCH v10 2/3 spi: Add Renesas R-Car Gen3 RPC-IF SPI controller driver
In reply to Mason YangAdd a driver for Renesas R-Car Gen3 RPC-IF SPI controller.
--- drivers/spi/Kconfig | 6 + drivers/spi/Makefile | 1 + drivers/spi/spi-renesas-rpc.c | 561 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 568 insertions(+) create mode 100644 drivers/spi/spi-renesas-rpc.c
drivers/spi/Kconfig +6 -0
@@ -564,6 +564,12 @@ config SPI_RSPI help SPI driver for Renesas RSPI and QSPI blocks. +config SPI_RENESAS_RPC + tristate "Renesas R-Car Gen3 RPC-IF controller" + depends on ARCH_RENESAS || COMPILE_TEST + help + SPI driver for Renesas R-Car Gen3 RPC-IF. + config SPI_QCOM_QSPI tristate "QTI QSPI controller" depends on ARCH_QCOM
drivers/spi/Makefile +1 -0
@@ -86,6 +86,7 @@ obj-$(CONFIG_SPI_QUP) += spi-qup.o obj-$(CONFIG_SPI_ROCKCHIP) += spi-rockchip.o obj-$(CONFIG_SPI_RB4XX) += spi-rb4xx.o obj-$(CONFIG_SPI_RSPI) += spi-rspi.o +obj-$(CONFIG_SPI_RENESAS_RPC) += spi-renesas-rpc.o obj-$(CONFIG_SPI_S3C24XX) += spi-s3c24xx-hw.o spi-s3c24xx-hw-y := spi-s3c24xx.o spi-s3c24xx-hw-$(CONFIG_SPI_S3C24XX_FIQ) += spi-s3c24xx-fiq.o
drivers/spi/spi-renesas-rpc.c new file +561 -0
561 lines not on this page · raw message
Signature · 1 line
1.9.1
Re: [PATCH v10 2/3] spi: Add Renesas R-Car Gen3 RPC-IF SPI controller driver
Quoted 4 lines · Mason Yang
Add a driver for Renesas R-Car Gen3 RPC-IF SPI controller.
Signed-off-by Mason Yang <[email protected]>Signed-off-by Sergei Shtylyov <[email protected]>
This patch looked good to me (you seem to have incorporated another patch of mine
here :-)). Since the patch is already carrying my signoff, I wouldn't add a Reviewed-by:
tag.
However, I believe that all manipulations with the RPC-IF hardware need to be moved
to the MFD driver, to be called from the SPI and HF subdrivers... doesn't seem an easy task though...
MBR, Sergei
PATCH v10 3/3 dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller bindings
In reply to Mason YangDocument the bindings used by the Renesas R-Car Gen3 RPC-IF MFD controller.
--- .../devicetree/bindings/mfd/mfd-renesas-rpc.txt | 37 ++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +37 -0
@@ -0,0 +1,37 @@ +Renesas R-Car Gen3 RPC-IF MFD controller Device Tree Bindings +------------------------------------------------------------- + +Required properties: +- compatible: should be an SoC-specific compatible value, followed by + "renesas,rcar-gen3-rpc" as a fallback. + supported SoC-specific values are: + "renesas,r8a77995-rpc" (R-Car D3) +- reg: should contain 2 entries, one for the base address of rpc-if registers, + and one for the direct mapping area +- reg-names: should contain "regs", and "dirmap" +- clocks: should contain 1 entries for the module's clock +- clock-names: should contain "rpc" +- #address-cells: should be 1 +- #size-cells: should be 0 + +Example: + + rpc: rpc-if@ee200000 { + compatible = "renesas,r8a77995-rpc", "renesas,rcar-gen3-rpc"; + reg = <0 0xee200000 0 0x200>, <0 0x08000000 0 0x4000000>; + reg-names = "regs", "dirmap"; + clocks = <&cpg CPG_MOD 917>; + clock-names = "rpc"; + power-domains = <&sysc R8A77995_PD_ALWAYS_ON>; + resets = <&cpg 917>; + #address-cells = <1>; + #size-cells = <0>; + + flash@0 { + compatible = "jedec,spi-nor"; + reg = <0>; + spi-max-frequency = <40000000>; + spi-tx-bus-width = <1>; + spi-rx-bus-width = <1>; + }; + };
Signature · 1 line
1.9.1
Re: [PATCH v10 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller bindings
Quoted 15 lines · Mason Yang
Document the bindings used by the Renesas R-Car Gen3 RPC-IF MFD controller.
Signed-off-by Mason Yang <[email protected]>--- .../devicetree/bindings/mfd/mfd-renesas-rpc.txt | 37 ++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txtDocumentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +1
-0@@ -0,0 +1,37 @@ +Renesas R-Car Gen3 RPC-IF MFD controller Device Tree Bindings
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 11
Quoted 10 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +10
-0+------------------------------------------------------------- + +Required properties: +- compatible: should be an SoC-specific compatible value, followed by + "renesas,rcar-gen3-rpc" as a fallback. + supported SoC-specific values are: + "renesas,r8a77995-rpc" (R-Car D3) +- reg: should contain 2 entries, one for the base address of rpc-if registers, + and one for the direct mapping area +- reg-names: should contain "regs", and "dirmap"
The device tree describes the hardware, not the driver. Why did you remove
the "wbuf" area?
[...]
MBR, Sergei
Re: [PATCH v10 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller bindings
Hello,
Quoted 7 lines
Re: [PATCH v10 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller bindings
Quoted 1 line · Mason Yang
Document the bindings used by the Renesas R-Car Gen3 RPC-IF MFD
controller.
Quoted 26 lines
Quoted 4 lines
Signed-off-by Mason Yang <[email protected]>--- .../devicetree/bindings/mfd/mfd-renesas-rpc.txt | 37 ++++++++++++++++++++++
Quoted 2 lines
1 file changed, 37 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt
Review
Quoted 2 lines
(quoted diff) +0
-0rpc.txt
b/Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txtQuoted 5 lines
new file mode 100644
index 0000000..bfb3d29Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 9
Quoted 9 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +9
-0@@ -0,0 +1,37 @@ +Renesas R-Car Gen3 RPC-IF MFD controller Device Tree Bindings +------------------------------------------------------------- + +Required properties: +- compatible: should be an SoC-specific compatible value, followed by + "renesas,rcar-gen3-rpc" as a fallback. + supported SoC-specific values are: + "renesas,r8a77995-rpc" (R-Car D3) +- reg: should contain 2 entries, one for the base address of rpc-if registers,
Quoted 4 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 11
Quoted 2 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +2
-0+ and one for the direct mapping area +- reg-names: should contain "regs", and "dirmap"The device tree describes the hardware, not the driver. Why did you
remove
Quoted 1 line
the "wbuf" area?
I don't think we should describe the hardware that driver did not implement it
because there are still many RPC registers we don't use them.
best regards,
Mason
CONFIDENTIALITY NOTE:
This e-mail and any attachments may contain confidential information and/or personal data, which is protected by applicable laws. Please be reminded that duplication, disclosure, distribution, or use of this e-mail (and/or its attachments) or any part thereof is prohibited. If you receive this e-mail in error, please notify us immediately and delete this mail as well as its attachment(s) from your system. In addition, please be informed that collection, processing, and/or use of personal data is prohibited unless expressly permitted by personal data protection laws. Thank you for your attention and cooperation.
Macronix International Co., Ltd.
=====================================================================
============================================================================
CONFIDENTIALITY NOTE:
This e-mail and any attachments may contain confidential information and/or personal data, which is protected by applicable laws. Please be reminded that duplication, disclosure, distribution, or use of this e-mail (and/or its attachments) or any part thereof is prohibited. If you receive this e-mail in error, please notify us immediately and delete this mail as well as its attachment(s) from your system. In addition, please be informed that collection, processing, and/or use of personal data is prohibited unless expressly permitted by personal data protection laws. Thank you for your attention and cooperation.
Macronix International Co., Ltd.
=====================================================================
Re: [PATCH v10 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller bindings
Quoted 27 lines · On 16.04.2019 4:06, [email protected] wrote:
Quoted 27 lines
Quoted 5 lines
Document the bindings used by the Renesas R-Car Gen3 RPC-IF MFD controller.
Signed-off-by Mason Yang <[email protected]>---
.../devicetree/bindings/mfd/mfd-renesas-rpc.txt | 37 ++++++++++++++++++++++
Quoted 2 lines
1 file changed, 37 insertions(+)create mode 100644
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt
Review
Quoted 2 lines
(quoted diff) +0
-0rpc.txt
b/Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txtQuoted 5 lines
new file mode 100644
index 0000000..bfb3d29Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 9
Quoted 9 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +9
-0@@ -0,0 +1,37 @@ +Renesas R-Car Gen3 RPC-IF MFD controller Device Tree Bindings +------------------------------------------------------------- + +Required properties: +- compatible: should be an SoC-specific compatible value, followed by + "renesas,rcar-gen3-rpc" as a fallback. + supported SoC-specific values are: + "renesas,r8a77995-rpc" (R-Car D3) +- reg: should contain 2 entries, one for the base address of rpc-if registers,
Quoted 8 lines
Quoted 5 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 11
Quoted 2 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +2
-0+ and one for the direct mapping area +- reg-names: should contain "regs", and "dirmap"The device tree describes the hardware, not the driver. Why did you remove the "wbuf" area?
I don't think we should describe the hardware that driver did not implement it because there are still many RPC registers we don't use them.
I have to repeat: we describe the hardware, not the driver capabilities.
Quoted 2 lines
best regards,
Mason
MBR, Sergei
Re: [PATCH v10 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller bindings
Hello,
Quoted 30 lines
Subject
Re: [PATCH v10 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller bindings
Quoted 1 line · On 16.04.2019 4:06, [email protected] wrote:
Quoted 1 line
Quoted 1 line
Document the bindings used by the Renesas R-Car Gen3 RPC-IF
MFD controller.
Quoted 21 lines
Quoted 21 lines
Quoted 4 lines
Signed-off-by Mason Yang <[email protected]>--- .../devicetree/bindings/mfd/mfd-renesas-rpc.txt | 37 ++++++++++++++++++++++
Quoted 2 lines
1 file changed, 37 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt
Review
Quoted 2 lines
(quoted diff) +0
-0rpc.txt
b/Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txtQuoted 10 lines
new file mode 100644
index 0000000..bfb3d29Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +5
-0@@ -0,0 +1,37 @@ +Renesas R-Car Gen3 RPC-IF MFD controller Device Tree Bindings +------------------------------------------------------------- + +Required properties: +- compatible: should be an SoC-specific compatible value,
followed by
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt
Quoted 4 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +4
-0+ "renesas,rcar-gen3-rpc" as a fallback. + supported SoC-specific values are: + "renesas,r8a77995-rpc" (R-Car D3) +- reg: should contain 2 entries, one for the base address of
rpc-
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
if registers,
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 11
Quoted 2 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +2
-0+ and one for the direct mapping area +- reg-names: should contain "regs", and "dirmap"The device tree describes the hardware, not the driver. Why
Quoted 8 lines
did you remove
Quoted 3 lines
Quoted 1 line
the "wbuf" area?
I don't think we should describe the hardware that driver did not
implement it
Quoted 1 line
because there are still many RPC registers we don't use them.
I have to repeat: we describe the hardware, not the driver
capabilities.
how about:
- reg: should contain three register areas:
first for the base address of rpc-if registers, second for the direct mapping read mode and third for an optional write buffer area.
- reg-names: should contain "regs", "dirmap" and "wbuf"(optional).
is it OK ?
thanks & best regards,
Mason
CONFIDENTIALITY NOTE:
This e-mail and any attachments may contain confidential information and/or personal data, which is protected by applicable laws. Please be reminded that duplication, disclosure, distribution, or use of this e-mail (and/or its attachments) or any part thereof is prohibited. If you receive this e-mail in error, please notify us immediately and delete this mail as well as its attachment(s) from your system. In addition, please be informed that collection, processing, and/or use of personal data is prohibited unless expressly permitted by personal data protection laws. Thank you for your attention and cooperation.
Macronix International Co., Ltd.
=====================================================================
============================================================================
CONFIDENTIALITY NOTE:
This e-mail and any attachments may contain confidential information and/or personal data, which is protected by applicable laws. Please be reminded that duplication, disclosure, distribution, or use of this e-mail (and/or its attachments) or any part thereof is prohibited. If you receive this e-mail in error, please notify us immediately and delete this mail as well as its attachment(s) from your system. In addition, please be informed that collection, processing, and/or use of personal data is prohibited unless expressly permitted by personal data protection laws. Thank you for your attention and cooperation.
Macronix International Co., Ltd.
=====================================================================
Re: [PATCH v10 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller bindings
Hello!
Quoted 43 lines · On 04/18/2019 08:55 AM, [email protected] wrote:
Quoted 32 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Document the bindings used by the Renesas R-Car Gen3 RPC-IF
MFD controller.
Quoted 26 lines
Quoted 26 lines
Quoted 4 lines
Signed-off-by Mason Yang <[email protected]>--- .../devicetree/bindings/mfd/mfd-renesas-rpc.txt | 37 ++++++++++++++++++++++
Quoted 2 lines
1 file changed, 37 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt
Review
Quoted 2 lines
(quoted diff) +0
-0rpc.txt
b/Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txtQuoted 5 lines
new file mode 100644
index 0000000..bfb3d29Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 9
Quoted 9 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +9
-0@@ -0,0 +1,37 @@ +Renesas R-Car Gen3 RPC-IF MFD controller Device Tree Bindings +------------------------------------------------------------- + +Required properties: +- compatible: should be an SoC-specific compatible value, followed by + "renesas,rcar-gen3-rpc" as a fallback. + supported SoC-specific values are: + "renesas,r8a77995-rpc" (R-Car D3) +- reg: should contain 2 entries, one for the base address of rpc-if registers,
Quoted 4 lines
Quoted 4 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 11
Quoted 2 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +2
-0+ and one for the direct mapping area +- reg-names: should contain "regs", and "dirmap"The device tree describes the hardware, not the driver. Why
Quoted 8 lines
did you remove
Quoted 3 lines
Quoted 1 line
the "wbuf" area?
I don't think we should describe the hardware that driver did not
implement it
Quoted 1 line
because there are still many RPC registers we don't use them.
I have to repeat: we describe the hardware, not the driver capabilities.
how about:
Quoted 7 lines
- reg: should contain three register areas:
first for the base address of rpc-if registers, second for the direct mapping read mode and third for an optional write buffer area.
- reg-names: should contain "regs", "dirmap" and "wbuf"(optional).is it OK ?
No, the write buffer area is always there, at least on the gen3 chips.
(I forgot which other Renesas SoC has RPC-IF as well).
Quoted 2 lines
thanks & best regards,
Mason
MBR, Sergei
Re: [PATCH v10 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller bindings
Hello,
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Document the bindings used by the Renesas R-Car Gen3 RPC-IF
MFD controller.
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Signed-off-by Mason Yang <[email protected]>--- .../devicetree/bindings/mfd/mfd-renesas-rpc.txt | 37
+++++++++
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
+++++++++++++
Quoted 2 lines
1 file changed, 37 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt
Review
Quoted 2 lines
(quoted diff) +0
-0
a/Documentation/devicetree/bindings/mfd/mfd-renesas-
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
rpc.txt
b/Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
new file mode 100644
index 0000000..bfb3d29
---/dev/null
+++
b/Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt
Quoted 11 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 5
Quoted 6 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +5
-0@@ -0,0 +1,37 @@ +Renesas R-Car Gen3 RPC-IF MFD controller Device Tree Bindings +------------------------------------------------------------- + +Required properties: +- compatible: should be an SoC-specific compatible value,followed by
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +4
-0+ "renesas,rcar-gen3-rpc" as a fallback. + supported SoC-specific values are: + "renesas,r8a77995-rpc" (R-Car D3) +- reg: should contain 2 entries, one for the base address of
rpc-
Quoted 23 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
if registers,
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 11
Quoted 2 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +2
-0+ and one for the direct mapping area +- reg-names: should contain "regs", and "dirmap"The device tree describes the hardware, not the driver. Why
Quoted 8 lines
Quoted 8 lines
did you remove
Quoted 3 lines
Quoted 1 line
the "wbuf" area?
I don't think we should describe the hardware that driver did not
implement it
Quoted 1 line
because there are still many RPC registers we don't use them.
I have to repeat: we describe the hardware, not the driver
capabilities.
Quoted 9 lines
how about:
- reg: should contain three register areas:
first for the base address of rpc-if registers, second for the direct mapping read mode and third for an optional write buffer area.
- reg-names: should contain "regs", "dirmap" and "wbuf"(optional).
Quoted 3 lines
Quoted 1 line
is it OK ?
No, the write buffer area is always there, at least on the gen3
chips.
Quoted 1 line
(I forgot which other Renesas SoC has RPC-IF as well).
please don't forget that WBUF is part of read cache area and WBUF must be cleared by DRCR.RCF bit. I also have test writting some data into WBUF and reading them back will get some problems.
It means that WBUF is not good for a read-and-write application.
thanks & best regards,
Mason
CONFIDENTIALITY NOTE:
This e-mail and any attachments may contain confidential information and/or personal data, which is protected by applicable laws. Please be reminded that duplication, disclosure, distribution, or use of this e-mail (and/or its attachments) or any part thereof is prohibited. If you receive this e-mail in error, please notify us immediately and delete this mail as well as its attachment(s) from your system. In addition, please be informed that collection, processing, and/or use of personal data is prohibited unless expressly permitted by personal data protection laws. Thank you for your attention and cooperation.
Macronix International Co., Ltd.
=====================================================================
============================================================================
CONFIDENTIALITY NOTE:
This e-mail and any attachments may contain confidential information and/or personal data, which is protected by applicable laws. Please be reminded that duplication, disclosure, distribution, or use of this e-mail (and/or its attachments) or any part thereof is prohibited. If you receive this e-mail in error, please notify us immediately and delete this mail as well as its attachment(s) from your system. In addition, please be informed that collection, processing, and/or use of personal data is prohibited unless expressly permitted by personal data protection laws. Thank you for your attention and cooperation.
Macronix International Co., Ltd.
=====================================================================
Re: [PATCH v10 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF controller bindings
In reply to Sergei ShtylyovQuoted 49 lines · Sergei Shtylyov
Quoted 49 lines
Quoted 32 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Document the bindings used by the Renesas R-Car Gen3 RPC-IF
MFD controller.
Quoted 26 lines
Quoted 26 lines
Quoted 4 lines
Signed-off-by Mason Yang <[email protected]>--- .../devicetree/bindings/mfd/mfd-renesas-rpc.txt | 37 ++++++++++++++++++++++
Quoted 2 lines
1 file changed, 37 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt
Review
Quoted 2 lines
(quoted diff) +0
-0rpc.txt
b/Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txtQuoted 5 lines
new file mode 100644
index 0000000..bfb3d29Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 9
Quoted 9 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +9
-0@@ -0,0 +1,37 @@ +Renesas R-Car Gen3 RPC-IF MFD controller Device Tree Bindings +------------------------------------------------------------- + +Required properties: +- compatible: should be an SoC-specific compatible value, followed by + "renesas,rcar-gen3-rpc" as a fallback. + supported SoC-specific values are: + "renesas,r8a77995-rpc" (R-Car D3) +- reg: should contain 2 entries, one for the base address of rpc-if registers,
Quoted 4 lines
Quoted 4 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt line 11
Quoted 2 lines
Documentation/devicetree/bindings/mfd/mfd-renesas-rpc.txt new file +2
-0+ and one for the direct mapping area +- reg-names: should contain "regs", and "dirmap"The device tree describes the hardware, not the driver. Why
Quoted 8 lines
did you remove
Quoted 3 lines
Quoted 1 line
the "wbuf" area?
I don't think we should describe the hardware that driver did not
implement it
Quoted 1 line
because there are still many RPC registers we don't use them.
I have to repeat: we describe the hardware, not the driver capabilities.
how about:
- reg: should contain three register areas:
first for the base address of rpc-if registers, second for the direct mapping read mode and third for an optional write buffer area.
- reg-names: should contain "regs", "dirmap" and "wbuf"(optional).
Quoted 4 lines
Quoted 1 line
is it OK ?
No, the write buffer area is always there, at least on the gen3 chips.
(I forgot which other Renesas SoC has RPC-IF as well).
So it was RZ/A1. But it didn't have the HyperFlash mode...
Quoted 2 lines
Quoted 2 lines
thanks & best regards,
Mason
MBR, Sergei