* [PATCH v2 1/2] cmd: load: Fix code indentation
@ 2020-12-01 16:05 Michal Simek
2020-12-01 16:05 ` [PATCH v2 2/2] common: usb_storage: " Michal Simek
2020-12-01 16:09 ` [PATCH v2 1/2] cmd: load: " Michal Simek
0 siblings, 2 replies; 3+ messages in thread
From: Michal Simek @ 2020-12-01 16:05 UTC (permalink / raw)
To: u-boot
Reported by smatch like:
cmd/load.c:228 read_record() warn: inconsistent indenting
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
---
Changes in v2:
- One } was missing. Get it back.
arch/arm/dts/zynqmp.dtsi | 48 ++++++++--------------------------------
cmd/load.c | 9 ++++----
2 files changed, 13 insertions(+), 44 deletions(-)
diff --git a/arch/arm/dts/zynqmp.dtsi b/arch/arm/dts/zynqmp.dtsi
index 1634af0bd896..d5840ab8737e 100644
--- a/arch/arm/dts/zynqmp.dtsi
+++ b/arch/arm/dts/zynqmp.dtsi
@@ -672,6 +672,15 @@
power-domains = <&zynqmp_firmware PD_QSPI>;
};
+ psgtr: phy at fd400000 {
+ compatible = "xlnx,zynqmp-psgtr-v1.1";
+ status = "disabled";
+ reg = <0x0 0xfd400000 0x0 0x40000>,
+ <0x0 0xfd3d0000 0x0 0x1000>;
+ reg-names = "serdes", "siou";
+ #phy-cells = <4>;
+ };
+
rtc: rtc at ffa60000 {
compatible = "xlnx,zynqmp-rtc";
status = "disabled";
@@ -682,45 +691,6 @@
calibration = <0x8000>;
};
- serdes: zynqmp_phy at fd400000 {
- compatible = "xlnx,zynqmp-psgtr";
- status = "disabled";
- reg = <0x0 0xfd400000 0x0 0x40000>,
- <0x0 0xfd3d0000 0x0 0x1000>,
- <0x0 0xff5e0000 0x0 0x1000>;
- reg-names = "serdes", "siou", "lpd";
- nvmem-cells = <&soc_revision>;
- nvmem-cell-names = "soc_revision";
- resets = <&zynqmp_reset ZYNQMP_RESET_SATA>,
- <&zynqmp_reset ZYNQMP_RESET_USB0_CORERESET>,
- <&zynqmp_reset ZYNQMP_RESET_USB1_CORERESET>,
- <&zynqmp_reset ZYNQMP_RESET_USB0_HIBERRESET>,
- <&zynqmp_reset ZYNQMP_RESET_USB1_HIBERRESET>,
- <&zynqmp_reset ZYNQMP_RESET_USB0_APB>,
- <&zynqmp_reset ZYNQMP_RESET_USB1_APB>,
- <&zynqmp_reset ZYNQMP_RESET_DP>,
- <&zynqmp_reset ZYNQMP_RESET_GEM0>,
- <&zynqmp_reset ZYNQMP_RESET_GEM1>,
- <&zynqmp_reset ZYNQMP_RESET_GEM2>,
- <&zynqmp_reset ZYNQMP_RESET_GEM3>;
- reset-names = "sata_rst", "usb0_crst", "usb1_crst",
- "usb0_hibrst", "usb1_hibrst", "usb0_apbrst",
- "usb1_apbrst", "dp_rst", "gem0_rst",
- "gem1_rst", "gem2_rst", "gem3_rst";
- lane0: lane0 {
- #phy-cells = <4>;
- };
- lane1: lane1 {
- #phy-cells = <4>;
- };
- lane2: lane2 {
- #phy-cells = <4>;
- };
- lane3: lane3 {
- #phy-cells = <4>;
- };
- };
-
sata: ahci at fd0c0000 {
compatible = "ceva,ahci-1v84";
status = "disabled";
diff --git a/cmd/load.c b/cmd/load.c
index 9a3a16979c71..c6a7cc465153 100644
--- a/cmd/load.c
+++ b/cmd/load.c
@@ -228,12 +228,11 @@ static int read_record(char *buf, ulong len)
*p = c;
}
- /* Check for the console hangup (if any different from serial) */
- if (gd->jt->getc != getchar) {
- if (ctrlc()) {
- return (-1);
+ /* Check for the console hangup (if any different from serial) */
+ if (gd->jt->getc != getchar) {
+ if (ctrlc())
+ return (-1);
}
- }
}
/* line too long - truncate */
--
2.29.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH v2 2/2] common: usb_storage: Fix code indentation
2020-12-01 16:05 [PATCH v2 1/2] cmd: load: Fix code indentation Michal Simek
@ 2020-12-01 16:05 ` Michal Simek
2020-12-01 16:09 ` [PATCH v2 1/2] cmd: load: " Michal Simek
1 sibling, 0 replies; 3+ messages in thread
From: Michal Simek @ 2020-12-01 16:05 UTC (permalink / raw)
To: u-boot
Reported by smatch like:
common/usb_storage.c:430 us_one_transfer() warn: inconsistent indenting
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
---
(no changes since v1)
common/usb_storage.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/common/usb_storage.c b/common/usb_storage.c
index ff254419951f..7742bad1440d 100644
--- a/common/usb_storage.c
+++ b/common/usb_storage.c
@@ -431,8 +431,8 @@ static int us_one_transfer(struct us_data *us, int pipe, char *buf, int length)
return 0;
}
/* if our try counter reaches 0, bail out */
- debug(" %ld, data %d\n",
- us->pusb_dev->status, partial);
+ debug(" %ld, data %d\n",
+ us->pusb_dev->status, partial);
if (!maxtry--)
return result;
}
--
2.29.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH v2 1/2] cmd: load: Fix code indentation
2020-12-01 16:05 [PATCH v2 1/2] cmd: load: Fix code indentation Michal Simek
2020-12-01 16:05 ` [PATCH v2 2/2] common: usb_storage: " Michal Simek
@ 2020-12-01 16:09 ` Michal Simek
1 sibling, 0 replies; 3+ messages in thread
From: Michal Simek @ 2020-12-01 16:09 UTC (permalink / raw)
To: u-boot
On 01. 12. 20 17:05, Michal Simek wrote:
> Reported by smatch like:
> cmd/load.c:228 read_record() warn: inconsistent indenting
>
> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
> ---
>
> Changes in v2:
> - One } was missing. Get it back.
>
> arch/arm/dts/zynqmp.dtsi | 48 ++++++++--------------------------------
> cmd/load.c | 9 ++++----
> 2 files changed, 13 insertions(+), 44 deletions(-)
>
> diff --git a/arch/arm/dts/zynqmp.dtsi b/arch/arm/dts/zynqmp.dtsi
> index 1634af0bd896..d5840ab8737e 100644
> --- a/arch/arm/dts/zynqmp.dtsi
> +++ b/arch/arm/dts/zynqmp.dtsi
> @@ -672,6 +672,15 @@
> power-domains = <&zynqmp_firmware PD_QSPI>;
> };
>
> + psgtr: phy at fd400000 {
> + compatible = "xlnx,zynqmp-psgtr-v1.1";
> + status = "disabled";
> + reg = <0x0 0xfd400000 0x0 0x40000>,
> + <0x0 0xfd3d0000 0x0 0x1000>;
> + reg-names = "serdes", "siou";
> + #phy-cells = <4>;
> + };
> +
> rtc: rtc at ffa60000 {
> compatible = "xlnx,zynqmp-rtc";
> status = "disabled";
> @@ -682,45 +691,6 @@
> calibration = <0x8000>;
> };
>
> - serdes: zynqmp_phy at fd400000 {
> - compatible = "xlnx,zynqmp-psgtr";
> - status = "disabled";
> - reg = <0x0 0xfd400000 0x0 0x40000>,
> - <0x0 0xfd3d0000 0x0 0x1000>,
> - <0x0 0xff5e0000 0x0 0x1000>;
> - reg-names = "serdes", "siou", "lpd";
> - nvmem-cells = <&soc_revision>;
> - nvmem-cell-names = "soc_revision";
> - resets = <&zynqmp_reset ZYNQMP_RESET_SATA>,
> - <&zynqmp_reset ZYNQMP_RESET_USB0_CORERESET>,
> - <&zynqmp_reset ZYNQMP_RESET_USB1_CORERESET>,
> - <&zynqmp_reset ZYNQMP_RESET_USB0_HIBERRESET>,
> - <&zynqmp_reset ZYNQMP_RESET_USB1_HIBERRESET>,
> - <&zynqmp_reset ZYNQMP_RESET_USB0_APB>,
> - <&zynqmp_reset ZYNQMP_RESET_USB1_APB>,
> - <&zynqmp_reset ZYNQMP_RESET_DP>,
> - <&zynqmp_reset ZYNQMP_RESET_GEM0>,
> - <&zynqmp_reset ZYNQMP_RESET_GEM1>,
> - <&zynqmp_reset ZYNQMP_RESET_GEM2>,
> - <&zynqmp_reset ZYNQMP_RESET_GEM3>;
> - reset-names = "sata_rst", "usb0_crst", "usb1_crst",
> - "usb0_hibrst", "usb1_hibrst", "usb0_apbrst",
> - "usb1_apbrst", "dp_rst", "gem0_rst",
> - "gem1_rst", "gem2_rst", "gem3_rst";
> - lane0: lane0 {
> - #phy-cells = <4>;
> - };
> - lane1: lane1 {
> - #phy-cells = <4>;
> - };
> - lane2: lane2 {
> - #phy-cells = <4>;
> - };
> - lane3: lane3 {
> - #phy-cells = <4>;
> - };
> - };
> -
> sata: ahci at fd0c0000 {
> compatible = "ceva,ahci-1v84";
> status = "disabled";
> diff --git a/cmd/load.c b/cmd/load.c
> index 9a3a16979c71..c6a7cc465153 100644
> --- a/cmd/load.c
> +++ b/cmd/load.c
> @@ -228,12 +228,11 @@ static int read_record(char *buf, ulong len)
> *p = c;
> }
>
> - /* Check for the console hangup (if any different from serial) */
> - if (gd->jt->getc != getchar) {
> - if (ctrlc()) {
> - return (-1);
> + /* Check for the console hangup (if any different from serial) */
> + if (gd->jt->getc != getchar) {
> + if (ctrlc())
> + return (-1);
> }
> - }
> }
>
> /* line too long - truncate */
>
grrrr. Please ignore this series. I included stuff I didn't want to add
here.
M
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-12-01 16:09 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-01 16:05 [PATCH v2 1/2] cmd: load: Fix code indentation Michal Simek
2020-12-01 16:05 ` [PATCH v2 2/2] common: usb_storage: " Michal Simek
2020-12-01 16:09 ` [PATCH v2 1/2] cmd: load: " Michal Simek
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.