Re: [RFT][PATCH 4/7] net: dsa: microchip: Remove dev->txbuf

2018-12-21 Thread Andrew Lunn
On Fri, Dec 21, 2018 at 01:02:23AM +, tristram...@microchip.com wrote: > > On 12/20/2018 10:41 AM, Andrew Lunn wrote: > > > On Wed, Dec 19, 2018 at 05:20:33PM -0800, Florian Fainelli wrote: > > >> On 12/19/18 5:06 PM, Marek Vasut wrote: > > >>> Previous patches unconver that ksz_spi_write() is

Re: [RFT][PATCH 4/7] net: dsa: microchip: Remove dev->txbuf

2018-12-20 Thread Marek Vasut
On 12/21/2018 02:02 AM, tristram...@microchip.com wrote: >> On 12/20/2018 10:41 AM, Andrew Lunn wrote: >>> On Wed, Dec 19, 2018 at 05:20:33PM -0800, Florian Fainelli wrote: On 12/19/18 5:06 PM, Marek Vasut wrote: > Previous patches unconver that ksz_spi_write() is always ever called >

RE: [RFT][PATCH 4/7] net: dsa: microchip: Remove dev->txbuf

2018-12-20 Thread Tristram.Ha
> On 12/20/2018 10:41 AM, Andrew Lunn wrote: > > On Wed, Dec 19, 2018 at 05:20:33PM -0800, Florian Fainelli wrote: > >> On 12/19/18 5:06 PM, Marek Vasut wrote: > >>> Previous patches unconver that ksz_spi_write() is always ever called > >>> with len = 1, 2 or 4. We can thus drop the if (len > SPI_T

Re: [RFT][PATCH 4/7] net: dsa: microchip: Remove dev->txbuf

2018-12-20 Thread Marek Vasut
On 12/20/2018 02:20 AM, Florian Fainelli wrote: > On 12/19/18 5:06 PM, Marek Vasut wrote: >> Previous patches unconver that ksz_spi_write() is always ever called >> with len = 1, 2 or 4. We can thus drop the if (len > SPI_TX_BUF_LEN) >> check and we can also drop the allocation of the txbuf which i

Re: [RFT][PATCH 4/7] net: dsa: microchip: Remove dev->txbuf

2018-12-20 Thread Marek Vasut
On 12/20/2018 10:41 AM, Andrew Lunn wrote: > On Wed, Dec 19, 2018 at 05:20:33PM -0800, Florian Fainelli wrote: >> On 12/19/18 5:06 PM, Marek Vasut wrote: >>> Previous patches unconver that ksz_spi_write() is always ever called >>> with len = 1, 2 or 4. We can thus drop the if (len > SPI_TX_BUF_LEN)

Re: [RFT][PATCH 4/7] net: dsa: microchip: Remove dev->txbuf

2018-12-20 Thread Andrew Lunn
On Wed, Dec 19, 2018 at 05:20:33PM -0800, Florian Fainelli wrote: > On 12/19/18 5:06 PM, Marek Vasut wrote: > > Previous patches unconver that ksz_spi_write() is always ever called > > with len = 1, 2 or 4. We can thus drop the if (len > SPI_TX_BUF_LEN) > > check and we can also drop the allocation

Re: [RFT][PATCH 4/7] net: dsa: microchip: Remove dev->txbuf

2018-12-19 Thread Florian Fainelli
On 12/19/18 5:06 PM, Marek Vasut wrote: > Previous patches unconver that ksz_spi_write() is always ever called > with len = 1, 2 or 4. We can thus drop the if (len > SPI_TX_BUF_LEN) > check and we can also drop the allocation of the txbuf which is part > of the driver data. This wastes 256 bytes fo

[RFT][PATCH 4/7] net: dsa: microchip: Remove dev->txbuf

2018-12-19 Thread Marek Vasut
Previous patches unconver that ksz_spi_write() is always ever called with len = 1, 2 or 4. We can thus drop the if (len > SPI_TX_BUF_LEN) check and we can also drop the allocation of the txbuf which is part of the driver data. This wastes 256 bytes for no reason and can be replaced with 8-byte stac