On Wed, Nov 24, 2021 at 12:37:00PM +0000, Shubhrajyoti Datta wrote: > > > > -----Original Message----- > > From: Greg KH <gregkh@xxxxxxxxxxxxxxxxxxx> > > Sent: Wednesday, November 24, 2021 3:38 PM > > To: Shubhrajyoti Datta <shubhraj@xxxxxxxxxx> > > Cc: linux-serial@xxxxxxxxxxxxxxx; jirislaby@xxxxxxxxxx; jacmet@xxxxxxxxxx; git > > <git@xxxxxxxxxx> > > Subject: Re: [PATCH v2] serial-uartlite: Remove an un-necessary read of control > > register > > > > On Tue, Nov 23, 2021 at 06:43:48PM +0530, Shubhrajyoti Datta wrote: > > > The control register is a writeonly register that's why reading it > > > doesn't make any sense. > > > The manual states "This is a write-only register. Issuing a read > > > request to the control register generates the read acknowledgment with zero > > data." > > > > Are you sure this is ok to remove? Usually you have to do a read after a write to > > ensure that the write succeeded. > > > > What ensures that the write succeeded now if you remove this read? > > I do not find the mention of a read requirement in the manual. Look at your hardware bus documentation. > Also in the current code in ulite_console_write and in ulite_startup we are writing without a > read. So is that a bug there? I am _very_ loath to remove reads like until you can guarantee that it will not break anything. Please work with your hardware designers to ensure this. thanks, greg k-h