The two patch are used to fix known issues.
Hayes Wang (2):
eth/r8152: free previous memory if r8152_eth_probe fail
eth/r8152: fix the aggregation issue
drivers/usb/eth/r8152.c | 26 ++
drivers/usb/eth/r8152.h | 5 +
2 files changed, 27 insertions(+), 4
Remove the redundant setting for USB_RX_EARLY_SIZE. Besides, for
RTL8153B, it is necessary to notify the hardware of the changes
of the aggregation settings.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c | 17 +++--
drivers/usb/eth/r8152.h | 5 +
2 files changed, 20
The r8152_eth_probe() may allocate a memory for ss->dev_priv.
It has to be freed if r8152_eth_probe() fails finally.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c | 9 +++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/eth/r8152.c b/drivers/usb/eth/r8
This is used to support RTL8153B and RTL8154B.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c| 207 -
drivers/usb/eth/r8152.h| 41 +++-
drivers/usb/eth/r8152_fw.c | 170 ++
3 files changed, 414 insertions(+), 4
Reset bmu after disabling Tx/Rx. This is used to clear the FIFO of
Tx/Rx. The remained data may be transferred after Tx/Rx is re-enabled.
And it results in garbage data.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c | 14 ++
drivers/usb/eth/r8152.h | 7 ++-
2 files
.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.h| 13 ++---
drivers/usb/eth/r8152_fw.c | 58 ++
2 files changed, 36 insertions(+), 35 deletions(-)
diff --git a/drivers/usb/eth/r8152.h b/drivers/usb/eth/r8152.h
index 4daf4ee87d..710637d7a2 100644
--- a
Some settings of PHY have to work after resetting PHY.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/eth/r8152.c b/drivers/usb/eth/r8152.c
index 041cb22dd3..7f988543a1 100644
--- a/drivers/usb/eth/r8152.c
.
v1:
The first two patched are some improvements. And the last two patches
are used to support RTL8153B and RTL8154B.
Hayes Wang (4):
eth/r8152: reset bmu after disabling Tx/Rx
eth/r8152: reset PHY after setting it
eth/r8152: modify rtl_clear_bp function
eth/r8152: support RTL8153B/RTL8154B
Marek Vasut [mailto:ma...@denx.de]
> Sent: Friday, June 12, 2020 7:53 PM
[...]
> Try this:
>
> ocp_data = r8152_efuse_read(tp, 0x7d);
> ocp_data = (ocp_data & 0x1fff0) >> 1) | (ocp_data & 0x7);
> if (data != 0x)
> ocp_reg_write(tp, OCP_ADC_IOFFSET, data);
I thi
Marek Vasut [mailto:ma...@denx.de]
> Sent: Friday, June 12, 2020 8:05 AM
[...]
> > The real data (16-bit) would be inserted a dummy bit,
> > and store the 17-bit to efuse offset 0x7d. Therefore, when
> > reading the 17-bit data from efuse, we have to remove the
> > dummy to get the real data.
>
>
Marek Vasut [mailto:ma...@denx.de]
> Sent: Wednesday, June 10, 2020 9:21 PM
[...]
> > + /* ADC Bias Calibration:
> > +* read efuse offset 0x7d to get a 17-bit data. Remove the
> >> dummy/fake
> > +* bit (bit3) to rebuild the real 16-bit data. Write the data
>
Marek Vasut [mailto:ma...@denx.de]
> Sent: Wednesday, June 10, 2020 7:05 PM
[...]
> >>> +static void rtl_reset_bmu(struct r8152 *tp)
> >>> +{
> >>> + u32 ocp_data;
> >>
> >> You're writing a byte, shouldn't that be u8 ?
> >
> > The minimum length which is used to read or write
> > the register of t
Marek Vasut [mailto:ma...@denx.de]
> Sent: Wednesday, June 10, 2020 8:54 PM
[...]
> >>> + /* ADC Bias Calibration:
> >>> + * read efuse offset 0x7d to get a 17-bit data. Remove the
> dummy/fake
> >>> + * bit (bit3) to rebuild the real 16-bit data. Write the data to the
> >>> + * ADC ioffset.
> >
Marek Vasut [mailto:ma...@denx.de]
> Sent: Tuesday, June 09, 2020 10:27 PM
[...]
> > + /* ADC Bias Calibration:
> > +* read efuse offset 0x7d to get a 17-bit data. Remove the dummy/fake
> > +* bit (bit3) to rebuild the real 16-bit data. Write the data to the
> > +* ADC ioffset.
> > +
Marek Vasut [mailto:ma...@denx.de]
> Sent: Tuesday, June 09, 2020 10:22 PM
[...]
> > - bmcr = BMCR_ANENABLE | BMCR_ANRESTART;
> > + bmcr = BMCR_ANENABLE | BMCR_ANRESTART | BMCR_RESET;
>
> Do you really need to reset a PHY while resetting the autonegotiation ?
> I think if you r
Marek Vasut [mailto:ma...@denx.de]
> Sent: Tuesday, June 09, 2020 10:21 PM
[...]
> > +static void rtl_reset_bmu(struct r8152 *tp)
> > +{
> > + u32 ocp_data;
>
> You're writing a byte, shouldn't that be u8 ?
The minimum length which is used to read or write
the register of the device through con
The original rtl_clear_bp() is used to clear the firmware of both
PLA and USB MCU. The new one could clear the firmware of PLA or
USB independently. It is unnecessary to clear firmware, if there
is no one to be updated.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.h| 20
This is used to support RTL8153B and RTL8154B.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c| 207 -
drivers/usb/eth/r8152.h| 46 -
drivers/usb/eth/r8152_fw.c | 176 +++
3 files changed, 425 insertions
The first two patched are some improvements. And the last two patches
are used to support RTL8153B and RTL8154B.
Hayes Wang (4):
eth/r8152: reset bmu after disabling Tx/Rx
eth/r8152: reset PHY after setting it
eth/r8152: modify rtl_clear_bp function
eth/r8152: support RTL8153B/RTL8154B
Reset bmu after disabling Tx/Rx. This is used to clear the FIFO of
Tx/Rx. The remained data may be transferred after Tx/Rx is re-enabled.
And it results in garbage data.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c | 14 ++
drivers/usb/eth/r8152.h | 7 ++-
2 files
Some settings of PHY have to work after resetting PHY.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/eth/r8152.c b/drivers/usb/eth/r8152.c
index dbb1721882..d774a0fa63 100644
--- a/drivers/usb/eth/r8152.c
: Hayes Wang
---
drivers/usb/eth/r8152.h| 8 +
drivers/usb/eth/r8152_fw.c | 481 -
2 files changed, 265 insertions(+), 224 deletions(-)
diff --git a/drivers/usb/eth/r8152.h b/drivers/usb/eth/r8152.h
index c7f62b8b3e..10e0da8eb1 100644
--- a/drivers/usb/eth
Marek Vasut [mailto:ma...@denx.de]
> Sent: Tuesday, June 02, 2020 7:59 PM
[...]
> Can you be more specific about the problem you are fixing here ?
> What is the problem ?
> >>>
> >>> There is low probability that the device may be lost when rebooting.
> >>> Should I submit v2 to reword th
Marek Vasut [mailto:ma...@denx.de]
> Sent: Tuesday, June 02, 2020 7:02 PM
[...]
> >> Can you be more specific about the problem you are fixing here ?
> >> What is the problem ?
> >
> > There is low probability that the device may be lost when rebooting.
> > Should I submit v2 to reword the commit m
Marek Vasut [mailto:ma...@denx.de]
> Sent: Tuesday, June 02, 2020 12:46 AM
> > Update the firmware to improve compatibility for none-intel USB
> > host controller.
>
> Can you be more specific about the problem you are fixing here ?
> What is the problem ?
There is low probability that the device
Update the firmware to improve compatibility for none-intel USB
host controller.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.h| 8 +
drivers/usb/eth/r8152_fw.c | 481 -
2 files changed, 265 insertions(+), 224 deletions(-)
diff --git a/drivers
Marek Vasut [mailto:ma...@denx.de]
> Sent: Monday, May 25, 2020 9:01 PM
[...]
> > Excuse me. I test v1 only.
> > Do I have to resend v1 for patch #1?
>
> I'll pick V1, no worries.
Thanks.
Best Regards,
Hayes
Marek Vasut [mailto:ma...@denx.de]
> Sent: Monday, May 25, 2020 8:03 PM
[...]
ep_out_found = 1;
> > - }
> > + } else if ((ep_addr & USB_DIR_OUT) && !ep_out_found) {
>
>
> Sorry, I was wrong in my previous suggestion, the
v2:
Reword the patch #1 to make it easier to understand.
v1:
These are minor corrections for r8152 driver.
Hayes Wang (2):
eth/r8152: fix assigning the wrong endpoint
eth/r8152: fix typo in register name
drivers/usb/eth/r8152.c | 22 --
drivers/usb/eth/r8152.h | 4
The PAL_BDC_CR should be PLA_BDC_CR.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c | 8
drivers/usb/eth/r8152.h | 4 ++--
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/usb/eth/r8152.c b/drivers/usb/eth/r8152.c
index 9f7bc7986d..cef79cab49 100644
--- a
Although I think it never occurs, the code doesn't make sense, because
it may allow to assign an IN endpoint to ss->ep_out.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c | 14 ++
1 file changed, 6 insertions(+), 8 deletions(-)
diff --git a/drivers/usb/eth/r8152.c b
Marek Vasut [mailto:ma...@denx.de]
> Sent: Friday, May 22, 2020 9:22 PM
[...]
> > - if ((ep_addr & USB_DIR_IN) && !ep_in_found) {
> > - ss->ep_in = ep_addr &
> > - USB_ENDPOINT_NUMBER_MASK;
> > -
The PAL_BDC_CR should be PLA_BDC_CR.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c | 8
drivers/usb/eth/r8152.h | 4 ++--
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/usb/eth/r8152.c b/drivers/usb/eth/r8152.c
index 7c48663370..f201a1789b 100644
--- a
These are minor corrections for r8152 driver.
Hayes Wang (2):
eth/r8152: fix assigning the wrong endpoint
eth/r8152: fix typo in register name
drivers/usb/eth/r8152.c | 22 --
drivers/usb/eth/r8152.h | 4 ++--
2 files changed, 14 insertions(+), 12 deletions
Although I think it never occurs, the code doesn't make sense, because
it may allow to assign an IN endpoint to ss->ep_out.
Signed-off-by: Hayes Wang
---
drivers/usb/eth/r8152.c | 14 --
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/drivers/usb/eth/r8152.c b
35 matches
Mail list logo