All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [intel-linux-intel-lts:5.10/yocto 3/3] drivers/net/ethernet/intel/igc/igc_ptp.c:438:11: warning: variable 'nsec' set but not used
Date: Wed, 26 May 2021 13:18:09 +0800	[thread overview]
Message-ID: <202105261305.cHx2bCD5-lkp@intel.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 2126 bytes --]

tree:   https://github.com/intel/linux-intel-lts.git 5.10/yocto
head:   26a890b883303c93193cca69d5a096f550f93c6d
commit: 26a890b883303c93193cca69d5a096f550f93c6d [3/3] igc: Add support for DMA timestamp for non-PTP packets
config: x86_64-allyesconfig (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
        # https://github.com/intel/linux-intel-lts/commit/26a890b883303c93193cca69d5a096f550f93c6d
        git remote add intel-linux-intel-lts https://github.com/intel/linux-intel-lts.git
        git fetch --no-tags intel-linux-intel-lts 5.10/yocto
        git checkout 26a890b883303c93193cca69d5a096f550f93c6d
        # save the attached .config to linux build tree
        make W=1 ARCH=x86_64 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

   drivers/net/ethernet/intel/igc/igc_ptp.c: In function 'igc_ptp_dma_time_to_hwtstamp':
>> drivers/net/ethernet/intel/igc/igc_ptp.c:438:11: warning: variable 'nsec' set but not used [-Wunused-but-set-variable]
     438 |  u32 sec, nsec;
         |           ^~~~


vim +/nsec +438 drivers/net/ethernet/intel/igc/igc_ptp.c

   432	
   433	static void igc_ptp_dma_time_to_hwtstamp(struct igc_adapter *adapter,
   434						 struct skb_shared_hwtstamps *hwtstamps,
   435						 u64 systim)
   436	{
   437		struct igc_hw *hw = &adapter->hw;
 > 438		u32 sec, nsec;
   439	
   440		/* FIXME: use a workqueue to read these values to avoid
   441		 * reading these registers in the hot path.
   442		 */
   443		nsec = rd32(IGC_SYSTIML);
   444		sec = rd32(IGC_SYSTIMH);
   445	
   446		switch (adapter->hw.mac.type) {
   447		case igc_i225:
   448			memset(hwtstamps, 0, sizeof(*hwtstamps));
   449	
   450			/* HACK */
   451			hwtstamps->hwtstamp = ktime_set(sec, systim & 0xFFFFFFFF);
   452			break;
   453		default:
   454			break;
   455		}
   456	}
   457	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 64466 bytes --]

             reply	other threads:[~2021-05-26  5:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-26  5:18 kernel test robot [this message]
  -- strict thread matches above, loose matches on Subject: below --
2021-07-09 20:58 [intel-linux-intel-lts:5.10/yocto 3/3] drivers/net/ethernet/intel/igc/igc_ptp.c:438:11: warning: variable 'nsec' set but not used kernel test robot

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=202105261305.cHx2bCD5-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild-all@lists.01.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.