From: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
To: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
Cc: "Forest Bond" <forest@alittletooquiet.net>,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Guido Martínez" <guido@vanguardiasur.com.ar>,
"Malcolm Priestley" <tvboxspy@gmail.com>,
"Guillaume Clement" <gclement@baobob.org>,
"Joe Perches" <joe@perches.com>,
devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] staging: vt6655: mac.c: Remove unused function
Date: Mon, 8 Dec 2014 11:08:50 +0530 [thread overview]
Message-ID: <20141208053850.GA3971@sudip-PC> (raw)
In-Reply-To: <1417989764-18481-1-git-send-email-rickard_strandqvist@spectrumdigital.se>
On Sun, Dec 07, 2014 at 11:02:44PM +0100, Rickard Strandqvist wrote:
> Remove the function MACbCompareContext() that is not used anywhere.
>
> This was partially found by using a static code analysis program called cppcheck.
>
> Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
> ---
not applying to next-20141205
sudip
> drivers/staging/vt6655/mac.c | 42 ------------------------------------------
> drivers/staging/vt6655/mac.h | 1 -
> 2 files changed, 43 deletions(-)
>
> diff --git a/drivers/staging/vt6655/mac.c b/drivers/staging/vt6655/mac.c
> index e3b0b7f..8254879 100644
> --- a/drivers/staging/vt6655/mac.c
> +++ b/drivers/staging/vt6655/mac.c
> @@ -49,7 +49,6 @@
> * MACvSetPacketFilter - Set MAC Address Filter
> * MACvSaveContext - Save Context of MAC Registers
> * MACvRestoreContext - Restore Context of MAC Registers
> - * MACbCompareContext - Compare if values of MAC Registers same as Context
> * MACbSoftwareReset - Software Reset MAC
> * MACbSafeRxOff - Turn Off MAC Rx
> * MACbSafeTxOff - Turn Off MAC Tx
> @@ -702,47 +701,6 @@ void MACvRestoreContext(void __iomem *dwIoBase, unsigned char *pbyCxtBuf)
>
> /*
> * Description:
> - * Compare if MAC registers same as context buffer
> - *
> - * Parameters:
> - * In:
> - * dwIoBase - Base Address for MAC
> - * pbyCxtBuf - Context buffer
> - * Out:
> - * none
> - *
> - * Return Value: true if all values are the same; otherwise false
> - *
> - */
> -bool MACbCompareContext(void __iomem *dwIoBase, unsigned char *pbyCxtBuf)
> -{
> - unsigned long dwData;
> -
> - // compare MAC context to determine if this is a power lost init,
> - // return true for power remaining init, return false for power lost init
> -
> - // compare CURR_RX_DESC_ADDR, CURR_TX_DESC_ADDR
> - VNSvInPortD(dwIoBase + MAC_REG_TXDMAPTR0, &dwData);
> - if (dwData != *(unsigned long *)(pbyCxtBuf + MAC_REG_TXDMAPTR0))
> - return false;
> -
> - VNSvInPortD(dwIoBase + MAC_REG_AC0DMAPTR, &dwData);
> - if (dwData != *(unsigned long *)(pbyCxtBuf + MAC_REG_AC0DMAPTR))
> - return false;
> -
> - VNSvInPortD(dwIoBase + MAC_REG_RXDMAPTR0, &dwData);
> - if (dwData != *(unsigned long *)(pbyCxtBuf + MAC_REG_RXDMAPTR0))
> - return false;
> -
> - VNSvInPortD(dwIoBase + MAC_REG_RXDMAPTR1, &dwData);
> - if (dwData != *(unsigned long *)(pbyCxtBuf + MAC_REG_RXDMAPTR1))
> - return false;
> -
> - return true;
> -}
> -
> -/*
> - * Description:
> * Software Reset MAC
> *
> * Parameters:
> diff --git a/drivers/staging/vt6655/mac.h b/drivers/staging/vt6655/mac.h
> index 0bf9375..811c459 100644
> --- a/drivers/staging/vt6655/mac.h
> +++ b/drivers/staging/vt6655/mac.h
> @@ -1006,7 +1006,6 @@ void MACvSetPacketFilter(void __iomem *dwIoBase, unsigned short wFilterType);
>
> void MACvSaveContext(void __iomem *dwIoBase, unsigned char *pbyCxtBuf);
> void MACvRestoreContext(void __iomem *dwIoBase, unsigned char *pbyCxtBuf);
> -bool MACbCompareContext(void __iomem *dwIoBase, unsigned char *pbyCxtBuf);
>
> bool MACbSoftwareReset(void __iomem *dwIoBase);
> bool MACbSafeSoftwareReset(void __iomem *dwIoBase);
> --
> 1.7.10.4
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
next prev parent reply other threads:[~2014-12-08 5:39 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-07 22:02 [PATCH] staging: vt6655: mac.c: Remove unused function Rickard Strandqvist
2014-12-08 5:38 ` Sudip Mukherjee [this message]
2015-01-13 3:34 ` Greg Kroah-Hartman
2015-01-17 15:51 ` Rickard Strandqvist
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20141208053850.GA3971@sudip-PC \
--to=sudipm.mukherjee@gmail.com \
--cc=devel@driverdev.osuosl.org \
--cc=forest@alittletooquiet.net \
--cc=gclement@baobob.org \
--cc=gregkh@linuxfoundation.org \
--cc=guido@vanguardiasur.com.ar \
--cc=joe@perches.com \
--cc=linux-kernel@vger.kernel.org \
--cc=rickard_strandqvist@spectrumdigital.se \
--cc=tvboxspy@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox