On Mon, 18 Oct 2021, Karolina Drobnik wrote: > Fix line length warnings raised by checkpatch.pl in > rf.c file for `RFvWriteWakeProgSyn`,`RFbRawSetPower` > and `RFbAL7230SelectChannelPostProcess`functions. > > Signed-off-by: Karolina Drobnik <karolinadrobnik@xxxxxxxxx> > --- > drivers/staging/vt6655/rf.c | 66 +++++++++++++++++++++++++++---------- > 1 file changed, 49 insertions(+), 17 deletions(-) > > diff --git a/drivers/staging/vt6655/rf.c b/drivers/staging/vt6655/rf.c > index a6f17162d017..206d34b555bc 100644 > --- a/drivers/staging/vt6655/rf.c > +++ b/drivers/staging/vt6655/rf.c > @@ -699,11 +699,17 @@ bool RFvWriteWakeProgSyn(struct vnt_private *priv, unsigned char byRFType, > return false; > > for (ii = 0; ii < CB_AL2230_INIT_SEQ; ii++) > - MACvSetMISCFifo(priv, (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), dwAL2230InitTable[ii]); > + MACvSetMISCFifo(priv, > + (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), > + dwAL2230InitTable[ii]); > > - MACvSetMISCFifo(priv, (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), dwAL2230ChannelTable0[uChannel - 1]); > + MACvSetMISCFifo(priv, > + (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), > + dwAL2230ChannelTable0[uChannel - 1]); > ii++; > - MACvSetMISCFifo(priv, (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), dwAL2230ChannelTable1[uChannel - 1]); > + MACvSetMISCFifo(priv, > + (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), > + dwAL2230ChannelTable1[uChannel - 1]); > break; > > /* Need to check, PLLON need to be low for channel setting */ > @@ -716,17 +722,28 @@ bool RFvWriteWakeProgSyn(struct vnt_private *priv, unsigned char byRFType, > > if (uChannel <= CB_MAX_CHANNEL_24G) { > for (ii = 0; ii < CB_AL7230_INIT_SEQ; ii++) > - MACvSetMISCFifo(priv, (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), dwAL7230InitTable[ii]); > + MACvSetMISCFifo(priv, > + (unsigned short)(MISCFIFO_SYNDATA_IDX > + + ii), dwAL7230InitTable[ii]); The placement of + ii) is not a good solution. Can it be moved up to the line before? Likewise in the next case. > } else { > for (ii = 0; ii < CB_AL7230_INIT_SEQ; ii++) > - MACvSetMISCFifo(priv, (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), dwAL7230InitTableAMode[ii]); > + MACvSetMISCFifo(priv, > + (unsigned short)(MISCFIFO_SYNDATA_IDX > + + ii), > + dwAL7230InitTableAMode[ii]); > } > > - MACvSetMISCFifo(priv, (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), dwAL7230ChannelTable0[uChannel - 1]); > + MACvSetMISCFifo(priv, > + (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), > + dwAL7230ChannelTable0[uChannel - 1]); > ii++; > - MACvSetMISCFifo(priv, (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), dwAL7230ChannelTable1[uChannel - 1]); > + MACvSetMISCFifo(priv, > + (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), > + dwAL7230ChannelTable1[uChannel - 1]); > ii++; > - MACvSetMISCFifo(priv, (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), dwAL7230ChannelTable2[uChannel - 1]); > + MACvSetMISCFifo(priv, > + (unsigned short)(MISCFIFO_SYNDATA_IDX + ii), > + dwAL7230ChannelTable2[uChannel - 1]); > break; > > case RF_NOTHING: > @@ -736,7 +753,8 @@ bool RFvWriteWakeProgSyn(struct vnt_private *priv, unsigned char byRFType, > return false; > } > > - MACvSetMISCFifo(priv, MISCFIFO_SYNINFO_IDX, (unsigned long)MAKEWORD(bySleepCount, byInitCount)); > + MACvSetMISCFifo(priv, MISCFIFO_SYNINFO_IDX, > + (unsigned long)MAKEWORD(bySleepCount, byInitCount)); > > return true; > } > @@ -836,20 +854,32 @@ bool RFbRawSetPower(struct vnt_private *priv, unsigned char byPwr, > case RF_AIROHA: > ret &= IFRFbWriteEmbedded(priv, dwAL2230PowerTable[byPwr]); > if (rate <= RATE_11M) > - ret &= IFRFbWriteEmbedded(priv, 0x0001B400 + (BY_AL2230_REG_LEN << 3) + IFREGCTL_REGW); > + ret &= IFRFbWriteEmbedded(priv, 0x0001B400 > + + (BY_AL2230_REG_LEN << 3) > + + IFREGCTL_REGW); Also not great. Maybe there could be a newline before the 0x0001B400 too. julia > else > - ret &= IFRFbWriteEmbedded(priv, 0x0005A400 + (BY_AL2230_REG_LEN << 3) + IFREGCTL_REGW); > + ret &= IFRFbWriteEmbedded(priv, 0x0005A400 > + + (BY_AL2230_REG_LEN << 3) > + + IFREGCTL_REGW); > > break; > > case RF_AL2230S: > ret &= IFRFbWriteEmbedded(priv, dwAL2230PowerTable[byPwr]); > if (rate <= RATE_11M) { > - ret &= IFRFbWriteEmbedded(priv, 0x040C1400 + (BY_AL2230_REG_LEN << 3) + IFREGCTL_REGW); > - ret &= IFRFbWriteEmbedded(priv, 0x00299B00 + (BY_AL2230_REG_LEN << 3) + IFREGCTL_REGW); > + ret &= IFRFbWriteEmbedded(priv, 0x040C1400 > + + (BY_AL2230_REG_LEN << 3) > + + IFREGCTL_REGW); > + ret &= IFRFbWriteEmbedded(priv, 0x00299B00 > + + (BY_AL2230_REG_LEN << 3) > + + IFREGCTL_REGW); > } else { > - ret &= IFRFbWriteEmbedded(priv, 0x0005A400 + (BY_AL2230_REG_LEN << 3) + IFREGCTL_REGW); > - ret &= IFRFbWriteEmbedded(priv, 0x00099B00 + (BY_AL2230_REG_LEN << 3) + IFREGCTL_REGW); > + ret &= IFRFbWriteEmbedded(priv, 0x0005A400 > + + (BY_AL2230_REG_LEN << 3) > + + IFREGCTL_REGW); > + ret &= IFRFbWriteEmbedded(priv, 0x00099B00 > + + (BY_AL2230_REG_LEN << 3) > + + IFREGCTL_REGW); > } > > break; > @@ -921,7 +951,8 @@ bool RFbAL7230SelectChannelPostProcess(struct vnt_private *priv, > * register > * Channel Index 1~14 > */ > - if ((byOldChannel <= CB_MAX_CHANNEL_24G) && (byNewChannel > CB_MAX_CHANNEL_24G)) { > + if ((byOldChannel <= CB_MAX_CHANNEL_24G) && > + (byNewChannel > CB_MAX_CHANNEL_24G)) { > /* Change from 2.4G to 5G [Reg] */ > ret &= IFRFbWriteEmbedded(priv, dwAL7230InitTableAMode[2]); > ret &= IFRFbWriteEmbedded(priv, dwAL7230InitTableAMode[3]); > @@ -930,7 +961,8 @@ bool RFbAL7230SelectChannelPostProcess(struct vnt_private *priv, > ret &= IFRFbWriteEmbedded(priv, dwAL7230InitTableAMode[10]); > ret &= IFRFbWriteEmbedded(priv, dwAL7230InitTableAMode[12]); > ret &= IFRFbWriteEmbedded(priv, dwAL7230InitTableAMode[15]); > - } else if ((byOldChannel > CB_MAX_CHANNEL_24G) && (byNewChannel <= CB_MAX_CHANNEL_24G)) { > + } else if ((byOldChannel > CB_MAX_CHANNEL_24G) && > + (byNewChannel <= CB_MAX_CHANNEL_24G)) { > /* Change from 5G to 2.4G [Reg] */ > ret &= IFRFbWriteEmbedded(priv, dwAL7230InitTable[2]); > ret &= IFRFbWriteEmbedded(priv, dwAL7230InitTable[3]); > -- > 2.30.2 > > -- > You received this message because you are subscribed to the Google Groups "outreachy-kernel" group. > To unsubscribe from this group and stop receiving emails from it, send an email to outreachy-kernel+unsubscribe@xxxxxxxxxxxxxxxx. > To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20211018150526.9718-1-karolinadrobnik%40gmail.com. >