All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [jpirko-mlxsw:linecards 65/92] drivers/net/ethernet/mellanox/mlxsw/core_linecards.c:301:16: warning: variable 'end' set but not used
Date: Fri, 30 Apr 2021 13:14:18 +0800	[thread overview]
Message-ID: <202104301312.lYCbhFHl-lkp@intel.com> (raw)

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

tree:   https://github.com/jpirko/linux_mlxsw linecards
head:   f1abf7385107a947646d6b6edaa9b7594894a53a
commit: f05b460b1c388ff8c4b01c3bbdb707168862a6b2 [65/92] mlxsw: core_linecards: Add line card objects and implement provisioning
config: sh-allmodconfig (attached as .config)
compiler: sh4-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://github.com/jpirko/linux_mlxsw/commit/f05b460b1c388ff8c4b01c3bbdb707168862a6b2
        git remote add jpirko-mlxsw https://github.com/jpirko/linux_mlxsw
        git fetch --no-tags jpirko-mlxsw linecards
        git checkout f05b460b1c388ff8c4b01c3bbdb707168862a6b2
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross W=1 ARCH=sh 

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/mellanox/mlxsw/core_linecards.c: In function 'mlxsw_linecard_unprovision_work':
>> drivers/net/ethernet/mellanox/mlxsw/core_linecards.c:301:16: warning: variable 'end' set but not used [-Wunused-but-set-variable]
     301 |  unsigned long end;
         |                ^~~

Kconfig warnings: (for reference only)
   WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_PDC
   Depends on SOUND && !UML && SND && SND_SOC && SND_ATMEL_SOC && HAS_DMA
   Selected by
   - SND_ATMEL_SOC_SSC && SOUND && !UML && SND && SND_SOC && SND_ATMEL_SOC
   - SND_ATMEL_SOC_SSC_PDC && SOUND && !UML && SND && SND_SOC && SND_ATMEL_SOC && ATMEL_SSC


vim +/end +301 drivers/net/ethernet/mellanox/mlxsw/core_linecards.c

   293	
   294	static void mlxsw_linecard_unprovision_work(struct work_struct *work)
   295	{
   296		struct mlxsw_linecard *linecard =
   297			container_of(work, struct mlxsw_linecard, provision_work);
   298		struct mlxsw_linecards *linecards;
   299		enum mlxsw_reg_mbct_status status;
   300		struct mlxsw_core *mlxsw_core;
 > 301		unsigned long end;
   302		int err;
   303	
   304		mutex_lock(&linecard->lock);
   305	
   306		linecards = linecard->linecards;
   307		mlxsw_core = linecard->linecards->mlxsw_core;
   308	
   309		mlxsw_reg_mbct_pack(linecard->mbct_pl, linecard->slot_index,
   310				    MLXSW_REG_MBCT_OP_DEACTIVATE, 0, false, NULL);
   311		err = mlxsw_reg_write(mlxsw_core, MLXSW_REG(mbct), linecard->mbct_pl);
   312		if (err) {
   313			dev_err(linecards->bus_info->dev, "linecard %u: Failed to deactivate INI",
   314				linecard->slot_index);
   315			goto err_out;
   316		}
   317		mlxsw_reg_mbct_unpack(linecard->mbct_pl, &status);
   318		if (status == MLXSW_REG_MBCT_STATUS_DEACTIVATION_FAILED) {
   319			dev_err(linecards->bus_info->dev, "linecard %u: Failed to deactivate INI",
   320				linecard->slot_index);
   321			goto err_out;
   322		}
   323	
   324		end = jiffies + msecs_to_jiffies(MLXSW_LINECARD_INI_ERASE_WAIT_MSECS);
   325	
   326		mlxsw_reg_mbct_pack(linecard->mbct_pl, linecard->slot_index,
   327				    MLXSW_REG_MBCT_OP_ERASE_INI_IMAGE, 0,
   328				    false, NULL);
   329		err = mlxsw_reg_write(mlxsw_core, MLXSW_REG(mbct),
   330				      linecard->mbct_pl);
   331		if (err) {
   332			dev_err(linecards->bus_info->dev, "linecard %u: Failed to erase INI",
   333				linecard->slot_index);
   334			goto err_out;
   335		}
   336		mlxsw_reg_mbct_unpack(linecard->mbct_pl, &status);
   337		switch (status) {
   338		case MLXSW_REG_MBCT_STATUS_ERASE_COMPLETE:
   339			break;
   340		default:
   341			/* Should not happen, fall-through. */
   342		case MLXSW_REG_MBCT_STATUS_ERASE_FAILED:
   343			dev_err(linecards->bus_info->dev, "linecard %u: Failed to erase INI",
   344				linecard->slot_index);
   345			goto err_out;
   346		case MLXSW_REG_MBCT_STATUS_INI_IN_USE:
   347			dev_err(linecards->bus_info->dev, "linecard %u: Failed to wait for INI to be not used",
   348				linecard->slot_index);
   349			goto err_out;
   350		}
   351		goto out;
   352	
   353	err_out:
   354		mlxsw_linecard_provision_fail(linecard);
   355	out:
   356		mutex_unlock(&linecard->lock);
   357	}
   358	

---
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: 54293 bytes --]

                 reply	other threads:[~2021-04-30  5:14 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202104301312.lYCbhFHl-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.