From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com
Subject: [android-common:android12-5.4 5/5] drivers/power/supply/power_supply_sysfs.c:111:57: warning: initializer-string for array of 'char' truncates NUL terminator but destination lacks 'nonstring' attribute (32 chars into 31 available)
Date: Sat, 22 Nov 2025 04:07:51 +0100 [thread overview]
Message-ID: <202511220439.HR64VCt8-lkp@intel.com> (raw)
::::::
:::::: Manual check reason: "low confidence bisect report"
::::::
BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
TO: cros-kernel-buildreports@googlegroups.com
tree: https://android.googlesource.com/kernel/common android12-5.4
head: b2957a0ebc3b9949475a442f9e8ab64ccaa6e087
commit: 34b830881d43fb698761c1c45df62cf19c6aa363 [5/5] UPSTREAM: power: supply: core: Cleanup power supply sysfs attribute list
:::::: branch date: 5 days ago
:::::: commit date: 5 years ago
config: arm64-allnoconfig-bpf (https://download.01.org/0day-ci/archive/20251122/202511220439.HR64VCt8-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 15.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251122/202511220439.HR64VCt8-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/r/202511220439.HR64VCt8-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> drivers/power/supply/power_supply_sysfs.c:111:57: warning: initializer-string for array of 'char' truncates NUL terminator but destination lacks 'nonstring' attribute (32 chars into 31 available) [-Wunterminated-string-initialization]
111 | POWER_SUPPLY_ATTR(CHARGE_CONTROL_START_THRESHOLD),
| ^
drivers/power/supply/power_supply_sysfs.c:33:23: note: in definition of macro 'POWER_SUPPLY_ATTR'
33 | .attr_name = #_name "\0", \
| ^~~~~
vim +111 drivers/power/supply/power_supply_sysfs.c
105df60f207301 David Lechner 2017-05-15 73
34b830881d43fb Mathew King 2020-05-04 74 static struct power_supply_attr power_supply_attrs[] = {
34b830881d43fb Mathew King 2020-05-04 75 /* Properties of type `int' */
34b830881d43fb Mathew King 2020-05-04 76 POWER_SUPPLY_ATTR(STATUS),
34b830881d43fb Mathew King 2020-05-04 77 POWER_SUPPLY_ATTR(CHARGE_TYPE),
34b830881d43fb Mathew King 2020-05-04 78 POWER_SUPPLY_ATTR(HEALTH),
34b830881d43fb Mathew King 2020-05-04 79 POWER_SUPPLY_ATTR(PRESENT),
34b830881d43fb Mathew King 2020-05-04 80 POWER_SUPPLY_ATTR(ONLINE),
34b830881d43fb Mathew King 2020-05-04 81 POWER_SUPPLY_ATTR(AUTHENTIC),
34b830881d43fb Mathew King 2020-05-04 82 POWER_SUPPLY_ATTR(TECHNOLOGY),
34b830881d43fb Mathew King 2020-05-04 83 POWER_SUPPLY_ATTR(CYCLE_COUNT),
34b830881d43fb Mathew King 2020-05-04 84 POWER_SUPPLY_ATTR(VOLTAGE_MAX),
34b830881d43fb Mathew King 2020-05-04 85 POWER_SUPPLY_ATTR(VOLTAGE_MIN),
34b830881d43fb Mathew King 2020-05-04 86 POWER_SUPPLY_ATTR(VOLTAGE_MAX_DESIGN),
34b830881d43fb Mathew King 2020-05-04 87 POWER_SUPPLY_ATTR(VOLTAGE_MIN_DESIGN),
34b830881d43fb Mathew King 2020-05-04 88 POWER_SUPPLY_ATTR(VOLTAGE_NOW),
34b830881d43fb Mathew King 2020-05-04 89 POWER_SUPPLY_ATTR(VOLTAGE_AVG),
34b830881d43fb Mathew King 2020-05-04 90 POWER_SUPPLY_ATTR(VOLTAGE_OCV),
34b830881d43fb Mathew King 2020-05-04 91 POWER_SUPPLY_ATTR(VOLTAGE_BOOT),
34b830881d43fb Mathew King 2020-05-04 92 POWER_SUPPLY_ATTR(CURRENT_MAX),
34b830881d43fb Mathew King 2020-05-04 93 POWER_SUPPLY_ATTR(CURRENT_NOW),
34b830881d43fb Mathew King 2020-05-04 94 POWER_SUPPLY_ATTR(CURRENT_AVG),
34b830881d43fb Mathew King 2020-05-04 95 POWER_SUPPLY_ATTR(CURRENT_BOOT),
34b830881d43fb Mathew King 2020-05-04 96 POWER_SUPPLY_ATTR(POWER_NOW),
34b830881d43fb Mathew King 2020-05-04 97 POWER_SUPPLY_ATTR(POWER_AVG),
34b830881d43fb Mathew King 2020-05-04 98 POWER_SUPPLY_ATTR(CHARGE_FULL_DESIGN),
34b830881d43fb Mathew King 2020-05-04 99 POWER_SUPPLY_ATTR(CHARGE_EMPTY_DESIGN),
34b830881d43fb Mathew King 2020-05-04 100 POWER_SUPPLY_ATTR(CHARGE_FULL),
34b830881d43fb Mathew King 2020-05-04 101 POWER_SUPPLY_ATTR(CHARGE_EMPTY),
34b830881d43fb Mathew King 2020-05-04 102 POWER_SUPPLY_ATTR(CHARGE_NOW),
34b830881d43fb Mathew King 2020-05-04 103 POWER_SUPPLY_ATTR(CHARGE_AVG),
34b830881d43fb Mathew King 2020-05-04 104 POWER_SUPPLY_ATTR(CHARGE_COUNTER),
34b830881d43fb Mathew King 2020-05-04 105 POWER_SUPPLY_ATTR(CONSTANT_CHARGE_CURRENT),
34b830881d43fb Mathew King 2020-05-04 106 POWER_SUPPLY_ATTR(CONSTANT_CHARGE_CURRENT_MAX),
34b830881d43fb Mathew King 2020-05-04 107 POWER_SUPPLY_ATTR(CONSTANT_CHARGE_VOLTAGE),
34b830881d43fb Mathew King 2020-05-04 108 POWER_SUPPLY_ATTR(CONSTANT_CHARGE_VOLTAGE_MAX),
34b830881d43fb Mathew King 2020-05-04 109 POWER_SUPPLY_ATTR(CHARGE_CONTROL_LIMIT),
34b830881d43fb Mathew King 2020-05-04 110 POWER_SUPPLY_ATTR(CHARGE_CONTROL_LIMIT_MAX),
34b830881d43fb Mathew King 2020-05-04 @111 POWER_SUPPLY_ATTR(CHARGE_CONTROL_START_THRESHOLD),
34b830881d43fb Mathew King 2020-05-04 112 POWER_SUPPLY_ATTR(CHARGE_CONTROL_END_THRESHOLD),
34b830881d43fb Mathew King 2020-05-04 113 POWER_SUPPLY_ATTR(INPUT_CURRENT_LIMIT),
34b830881d43fb Mathew King 2020-05-04 114 POWER_SUPPLY_ATTR(INPUT_VOLTAGE_LIMIT),
34b830881d43fb Mathew King 2020-05-04 115 POWER_SUPPLY_ATTR(INPUT_POWER_LIMIT),
34b830881d43fb Mathew King 2020-05-04 116 POWER_SUPPLY_ATTR(ENERGY_FULL_DESIGN),
34b830881d43fb Mathew King 2020-05-04 117 POWER_SUPPLY_ATTR(ENERGY_EMPTY_DESIGN),
34b830881d43fb Mathew King 2020-05-04 118 POWER_SUPPLY_ATTR(ENERGY_FULL),
34b830881d43fb Mathew King 2020-05-04 119 POWER_SUPPLY_ATTR(ENERGY_EMPTY),
34b830881d43fb Mathew King 2020-05-04 120 POWER_SUPPLY_ATTR(ENERGY_NOW),
34b830881d43fb Mathew King 2020-05-04 121 POWER_SUPPLY_ATTR(ENERGY_AVG),
34b830881d43fb Mathew King 2020-05-04 122 POWER_SUPPLY_ATTR(CAPACITY),
34b830881d43fb Mathew King 2020-05-04 123 POWER_SUPPLY_ATTR(CAPACITY_ALERT_MIN),
34b830881d43fb Mathew King 2020-05-04 124 POWER_SUPPLY_ATTR(CAPACITY_ALERT_MAX),
34b830881d43fb Mathew King 2020-05-04 125 POWER_SUPPLY_ATTR(CAPACITY_LEVEL),
34b830881d43fb Mathew King 2020-05-04 126 POWER_SUPPLY_ATTR(TEMP),
34b830881d43fb Mathew King 2020-05-04 127 POWER_SUPPLY_ATTR(TEMP_MAX),
34b830881d43fb Mathew King 2020-05-04 128 POWER_SUPPLY_ATTR(TEMP_MIN),
34b830881d43fb Mathew King 2020-05-04 129 POWER_SUPPLY_ATTR(TEMP_ALERT_MIN),
34b830881d43fb Mathew King 2020-05-04 130 POWER_SUPPLY_ATTR(TEMP_ALERT_MAX),
34b830881d43fb Mathew King 2020-05-04 131 POWER_SUPPLY_ATTR(TEMP_AMBIENT),
34b830881d43fb Mathew King 2020-05-04 132 POWER_SUPPLY_ATTR(TEMP_AMBIENT_ALERT_MIN),
34b830881d43fb Mathew King 2020-05-04 133 POWER_SUPPLY_ATTR(TEMP_AMBIENT_ALERT_MAX),
34b830881d43fb Mathew King 2020-05-04 134 POWER_SUPPLY_ATTR(TIME_TO_EMPTY_NOW),
34b830881d43fb Mathew King 2020-05-04 135 POWER_SUPPLY_ATTR(TIME_TO_EMPTY_AVG),
34b830881d43fb Mathew King 2020-05-04 136 POWER_SUPPLY_ATTR(TIME_TO_FULL_NOW),
34b830881d43fb Mathew King 2020-05-04 137 POWER_SUPPLY_ATTR(TIME_TO_FULL_AVG),
34b830881d43fb Mathew King 2020-05-04 138 POWER_SUPPLY_ATTR(TYPE),
34b830881d43fb Mathew King 2020-05-04 139 POWER_SUPPLY_ATTR(USB_TYPE),
34b830881d43fb Mathew King 2020-05-04 140 POWER_SUPPLY_ATTR(SCOPE),
34b830881d43fb Mathew King 2020-05-04 141 POWER_SUPPLY_ATTR(PRECHARGE_CURRENT),
34b830881d43fb Mathew King 2020-05-04 142 POWER_SUPPLY_ATTR(CHARGE_TERM_CURRENT),
34b830881d43fb Mathew King 2020-05-04 143 POWER_SUPPLY_ATTR(CALIBRATE),
34b830881d43fb Mathew King 2020-05-04 144 /* Properties of type `const char *' */
34b830881d43fb Mathew King 2020-05-04 145 POWER_SUPPLY_ATTR(MODEL_NAME),
34b830881d43fb Mathew King 2020-05-04 146 POWER_SUPPLY_ATTR(MANUFACTURER),
34b830881d43fb Mathew King 2020-05-04 147 POWER_SUPPLY_ATTR(SERIAL_NUMBER),
34b830881d43fb Mathew King 2020-05-04 148 };
34b830881d43fb Mathew King 2020-05-04 149
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next reply other threads:[~2025-11-22 3:08 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-22 3:07 kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2025-11-22 5:55 [android-common:android12-5.4 5/5] drivers/power/supply/power_supply_sysfs.c:111:57: warning: initializer-string for array of 'char' truncates NUL terminator but destination lacks 'nonstring' attribute (32 chars into 31 available) kernel test robot
2025-11-29 18:23 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=202511220439.HR64VCt8-lkp@intel.com \
--to=lkp@intel.com \
--cc=oe-kbuild@lists.linux.dev \
/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.