linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [bug report] fsl/qe: setup clock source for TDM mode
@ 2018-01-31 15:29 Dan Carpenter
  2018-02-01  6:33 ` Qiang Zhao
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2018-01-31 15:29 UTC (permalink / raw)
  To: qiang.zhao; +Cc: linuxppc-dev

Hello Zhao Qiang,

The patch bb8b2062aff3: "fsl/qe: setup clock source for TDM mode"
from Jun 6, 2016, leads to the following static checker warning:

	drivers/soc/fsl/qe/ucc.c:629 ucc_get_tdm_sync_shift()
	warn: both sides of ternary the same: '30' RX_SYNC_SHIFT_BASE RX_SYNC_SHIFT_BASE

drivers/soc/fsl/qe/ucc.c
   625  static u32 ucc_get_tdm_sync_shift(enum comm_dir mode, u32 tdm_num)
   626  {
   627          u32 shift;
   628  
   629          shift = (mode == COMM_DIR_RX) ? RX_SYNC_SHIFT_BASE : RX_SYNC_SHIFT_BASE;
                                                                     ^^^^^^^^^^^^^^^^^^

Maybe this one should have been TX_?

   630          shift -= tdm_num * 2;
   631  
   632          return shift;
   633  }

regards,
dan carpenter

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-02-01  6:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-01-31 15:29 [bug report] fsl/qe: setup clock source for TDM mode Dan Carpenter
2018-02-01  6:33 ` Qiang Zhao

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).