lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202012272136.2Ih2ZAQe-lkp@intel.com>
Date:   Sun, 27 Dec 2020 21:48:49 +0800
From:   kernel test robot <lkp@...el.com>
To:     Guo Ren <guoren@...ux.alibaba.com>
Cc:     kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: net/sctp/outqueue.c:1380:1: warning: the frame size of 8200 bytes is
 larger than 1024 bytes

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   f838f8d2b694cf9d524dc4423e9dd2db13892f3f
commit: 18c07d23da5a48525b2955aa269b8bb108c19300 csky: Fixup calltrace panic
date:   8 months ago
config: csky-randconfig-r004-20201227 (attached as .config)
compiler: csky-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://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=18c07d23da5a48525b2955aa269b8bb108c19300
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout 18c07d23da5a48525b2955aa269b8bb108c19300
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=csky 

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

All warnings (new ones prefixed by >>):

   net/sctp/outqueue.c: In function 'sctp_outq_sack':
>> net/sctp/outqueue.c:1380:1: warning: the frame size of 8200 bytes is larger than 1024 bytes [-Wframe-larger-than=]
    1380 | }
         | ^


vim +1380 net/sctp/outqueue.c

^1da177e4c3f415 Linus Torvalds     2005-04-16  1216  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1217  /* This is where we REALLY process a SACK.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1218   *
^1da177e4c3f415 Linus Torvalds     2005-04-16  1219   * Process the SACK against the outqueue.  Mostly, this just frees
^1da177e4c3f415 Linus Torvalds     2005-04-16  1220   * things off the transmitted queue.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1221   */
edfee0339e681a7 Nicolas Dichtel    2012-10-03  1222  int sctp_outq_sack(struct sctp_outq *q, struct sctp_chunk *chunk)
^1da177e4c3f415 Linus Torvalds     2005-04-16  1223  {
^1da177e4c3f415 Linus Torvalds     2005-04-16  1224  	struct sctp_association *asoc = q->asoc;
edfee0339e681a7 Nicolas Dichtel    2012-10-03  1225  	struct sctp_sackhdr *sack = chunk->subh.sack_hdr;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1226  	struct sctp_transport *transport;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1227  	struct sctp_chunk *tchunk = NULL;
9dbc15f055f0539 Robert P. J. Day   2008-04-12  1228  	struct list_head *lchunk, *transport_list, *temp;
afd93b7be6e2473 Xin Long           2017-07-23  1229  	union sctp_sack_variable *frags = sack->variable;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1230  	__u32 sack_ctsn, ctsn, tsn;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1231  	__u32 highest_tsn, highest_new_tsn;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1232  	__u32 sack_a_rwnd;
95c961747284a6b Eric Dumazet       2012-04-15  1233  	unsigned int outstanding;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1234  	struct sctp_transport *primary = asoc->peer.primary_path;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1235  	int count_of_newacks = 0;
2cd9b822bfa79fc Vlad Yasevich      2008-06-19  1236  	int gap_ack_blocks;
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1237  	u8 accum_moved = 0;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1238  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1239  	/* Grab the association's destination address list. */
^1da177e4c3f415 Linus Torvalds     2005-04-16  1240  	transport_list = &asoc->peer.transport_addr_list;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1241  
f643ee295c1c63b Kevin Kou          2019-12-26  1242  	/* SCTP path tracepoint for congestion control debugging. */
f398efc14a9277b Kevin Kou          2019-12-27  1243  	if (trace_sctp_probe_path_enabled()) {
f398efc14a9277b Kevin Kou          2019-12-27  1244  		list_for_each_entry(transport, transport_list, transports)
f643ee295c1c63b Kevin Kou          2019-12-26  1245  			trace_sctp_probe_path(transport, asoc);
f643ee295c1c63b Kevin Kou          2019-12-26  1246  	}
f643ee295c1c63b Kevin Kou          2019-12-26  1247  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1248  	sack_ctsn = ntohl(sack->cum_tsn_ack);
2cd9b822bfa79fc Vlad Yasevich      2008-06-19  1249  	gap_ack_blocks = ntohs(sack->num_gap_ack_blocks);
196d67593439b03 Michele Baldessari 2012-12-01  1250  	asoc->stats.gapcnt += gap_ack_blocks;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1251  	/*
^1da177e4c3f415 Linus Torvalds     2005-04-16  1252  	 * SFR-CACC algorithm:
^1da177e4c3f415 Linus Torvalds     2005-04-16  1253  	 * On receipt of a SACK the sender SHOULD execute the
^1da177e4c3f415 Linus Torvalds     2005-04-16  1254  	 * following statements.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1255  	 *
^1da177e4c3f415 Linus Torvalds     2005-04-16  1256  	 * 1) If the cumulative ack in the SACK passes next tsn_at_change
^1da177e4c3f415 Linus Torvalds     2005-04-16  1257  	 * on the current primary, the CHANGEOVER_ACTIVE flag SHOULD be
^1da177e4c3f415 Linus Torvalds     2005-04-16  1258  	 * cleared. The CYCLING_CHANGEOVER flag SHOULD also be cleared for
^1da177e4c3f415 Linus Torvalds     2005-04-16  1259  	 * all destinations.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1260  	 * 2) If the SACK contains gap acks and the flag CHANGEOVER_ACTIVE
^1da177e4c3f415 Linus Torvalds     2005-04-16  1261  	 * is set the receiver of the SACK MUST take the following actions:
^1da177e4c3f415 Linus Torvalds     2005-04-16  1262  	 *
^1da177e4c3f415 Linus Torvalds     2005-04-16  1263  	 * A) Initialize the cacc_saw_newack to 0 for all destination
^1da177e4c3f415 Linus Torvalds     2005-04-16  1264  	 * addresses.
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1265  	 *
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1266  	 * Only bother if changeover_active is set. Otherwise, this is
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1267  	 * totally suboptimal to do on every SACK.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1268  	 */
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1269  	if (primary->cacc.changeover_active) {
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1270  		u8 clear_cycling = 0;
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1271  
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1272  		if (TSN_lte(primary->cacc.next_tsn_at_change, sack_ctsn)) {
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1273  			primary->cacc.changeover_active = 0;
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1274  			clear_cycling = 1;
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1275  		}
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1276  
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1277  		if (clear_cycling || gap_ack_blocks) {
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1278  			list_for_each_entry(transport, transport_list,
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1279  					transports) {
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1280  				if (clear_cycling)
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1281  					transport->cacc.cycling_changeover = 0;
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1282  				if (gap_ack_blocks)
^1da177e4c3f415 Linus Torvalds     2005-04-16  1283  					transport->cacc.cacc_saw_newack = 0;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1284  			}
^1da177e4c3f415 Linus Torvalds     2005-04-16  1285  		}
ab5216a5bd45375 Vlad Yasevich      2008-06-19  1286  	}
^1da177e4c3f415 Linus Torvalds     2005-04-16  1287  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1288  	/* Get the highest TSN in the sack. */
^1da177e4c3f415 Linus Torvalds     2005-04-16  1289  	highest_tsn = sack_ctsn;
2cd9b822bfa79fc Vlad Yasevich      2008-06-19  1290  	if (gap_ack_blocks)
2cd9b822bfa79fc Vlad Yasevich      2008-06-19  1291  		highest_tsn += ntohs(frags[gap_ack_blocks - 1].gab.end);
^1da177e4c3f415 Linus Torvalds     2005-04-16  1292  
bfa0d9843ac5feb Vlad Yasevich      2010-04-30  1293  	if (TSN_lt(asoc->highest_sacked, highest_tsn))
^1da177e4c3f415 Linus Torvalds     2005-04-16  1294  		asoc->highest_sacked = highest_tsn;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1295  
bfa0d9843ac5feb Vlad Yasevich      2010-04-30  1296  	highest_new_tsn = sack_ctsn;
2cd9b822bfa79fc Vlad Yasevich      2008-06-19  1297  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1298  	/* Run through the retransmit queue.  Credit bytes received
^1da177e4c3f415 Linus Torvalds     2005-04-16  1299  	 * and free those chunks that we can.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1300  	 */
edfee0339e681a7 Nicolas Dichtel    2012-10-03  1301  	sctp_check_transmitted(q, &q->retransmit, NULL, NULL, sack, &highest_new_tsn);
^1da177e4c3f415 Linus Torvalds     2005-04-16  1302  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1303  	/* Run through the transmitted queue.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1304  	 * Credit bytes received and free those chunks which we can.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1305  	 *
^1da177e4c3f415 Linus Torvalds     2005-04-16  1306  	 * This is a MASSIVE candidate for optimization.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1307  	 */
9dbc15f055f0539 Robert P. J. Day   2008-04-12  1308  	list_for_each_entry(transport, transport_list, transports) {
^1da177e4c3f415 Linus Torvalds     2005-04-16  1309  		sctp_check_transmitted(q, &transport->transmitted,
edfee0339e681a7 Nicolas Dichtel    2012-10-03  1310  				       transport, &chunk->source, sack,
edfee0339e681a7 Nicolas Dichtel    2012-10-03  1311  				       &highest_new_tsn);
^1da177e4c3f415 Linus Torvalds     2005-04-16  1312  		/*
^1da177e4c3f415 Linus Torvalds     2005-04-16  1313  		 * SFR-CACC algorithm:
^1da177e4c3f415 Linus Torvalds     2005-04-16  1314  		 * C) Let count_of_newacks be the number of
^1da177e4c3f415 Linus Torvalds     2005-04-16  1315  		 * destinations for which cacc_saw_newack is set.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1316  		 */
^1da177e4c3f415 Linus Torvalds     2005-04-16  1317  		if (transport->cacc.cacc_saw_newack)
^1da177e4c3f415 Linus Torvalds     2005-04-16  1318  			count_of_newacks++;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1319  	}
^1da177e4c3f415 Linus Torvalds     2005-04-16  1320  
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1321  	/* Move the Cumulative TSN Ack Point if appropriate.  */
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1322  	if (TSN_lt(asoc->ctsn_ack_point, sack_ctsn)) {
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1323  		asoc->ctsn_ack_point = sack_ctsn;
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1324  		accum_moved = 1;
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1325  	}
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1326  
2cd9b822bfa79fc Vlad Yasevich      2008-06-19  1327  	if (gap_ack_blocks) {
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1328  
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1329  		if (asoc->fast_recovery && accum_moved)
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1330  			highest_new_tsn = highest_tsn;
ea862c8d1f4a0d1 Vlad Yasevich      2010-04-30  1331  
2cd9b822bfa79fc Vlad Yasevich      2008-06-19  1332  		list_for_each_entry(transport, transport_list, transports)
^1da177e4c3f415 Linus Torvalds     2005-04-16  1333  			sctp_mark_missing(q, &transport->transmitted, transport,
^1da177e4c3f415 Linus Torvalds     2005-04-16  1334  					  highest_new_tsn, count_of_newacks);
^1da177e4c3f415 Linus Torvalds     2005-04-16  1335  	}
^1da177e4c3f415 Linus Torvalds     2005-04-16  1336  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1337  	/* Update unack_data field in the assoc. */
^1da177e4c3f415 Linus Torvalds     2005-04-16  1338  	sctp_sack_update_unack_data(asoc, sack);
^1da177e4c3f415 Linus Torvalds     2005-04-16  1339  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1340  	ctsn = asoc->ctsn_ack_point;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1341  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1342  	/* Throw away stuff rotting on the sack queue.  */
^1da177e4c3f415 Linus Torvalds     2005-04-16  1343  	list_for_each_safe(lchunk, temp, &q->sacked) {
^1da177e4c3f415 Linus Torvalds     2005-04-16  1344  		tchunk = list_entry(lchunk, struct sctp_chunk,
^1da177e4c3f415 Linus Torvalds     2005-04-16  1345  				    transmitted_list);
^1da177e4c3f415 Linus Torvalds     2005-04-16  1346  		tsn = ntohl(tchunk->subh.data_hdr->tsn);
5f9646c3d9f92a9 Vlad Yasevich      2008-02-05  1347  		if (TSN_lte(tsn, ctsn)) {
5f9646c3d9f92a9 Vlad Yasevich      2008-02-05  1348  			list_del_init(&tchunk->transmitted_list);
be4947bf46cb0e7 Xin Long           2016-09-29  1349  			if (asoc->peer.prsctp_capable &&
8dbdf1f5b09cb22 Xin Long           2016-07-09  1350  			    SCTP_PR_PRIO_ENABLED(chunk->sinfo.sinfo_flags))
8dbdf1f5b09cb22 Xin Long           2016-07-09  1351  				asoc->sent_cnt_removable--;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1352  			sctp_chunk_free(tchunk);
^1da177e4c3f415 Linus Torvalds     2005-04-16  1353  		}
5f9646c3d9f92a9 Vlad Yasevich      2008-02-05  1354  	}
^1da177e4c3f415 Linus Torvalds     2005-04-16  1355  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1356  	/* ii) Set rwnd equal to the newly received a_rwnd minus the
^1da177e4c3f415 Linus Torvalds     2005-04-16  1357  	 *     number of bytes still outstanding after processing the
^1da177e4c3f415 Linus Torvalds     2005-04-16  1358  	 *     Cumulative TSN Ack and the Gap Ack Blocks.
^1da177e4c3f415 Linus Torvalds     2005-04-16  1359  	 */
^1da177e4c3f415 Linus Torvalds     2005-04-16  1360  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1361  	sack_a_rwnd = ntohl(sack->a_rwnd);
8a0d19c5ed417c7 lucien             2015-12-05  1362  	asoc->peer.zero_window_announced = !sack_a_rwnd;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1363  	outstanding = q->outstanding_bytes;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1364  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1365  	if (outstanding < sack_a_rwnd)
^1da177e4c3f415 Linus Torvalds     2005-04-16  1366  		sack_a_rwnd -= outstanding;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1367  	else
^1da177e4c3f415 Linus Torvalds     2005-04-16  1368  		sack_a_rwnd = 0;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1369  
^1da177e4c3f415 Linus Torvalds     2005-04-16  1370  	asoc->peer.rwnd = sack_a_rwnd;
^1da177e4c3f415 Linus Torvalds     2005-04-16  1371  
8e0c3b73cec1b94 Xin Long           2017-12-15  1372  	asoc->stream.si->generate_ftsn(q, sack_ctsn);
^1da177e4c3f415 Linus Torvalds     2005-04-16  1373  
bb33381d0c97cde Daniel Borkmann    2013-06-28  1374  	pr_debug("%s: sack cumulative tsn ack:0x%x\n", __func__, sack_ctsn);
bb33381d0c97cde Daniel Borkmann    2013-06-28  1375  	pr_debug("%s: cumulative tsn ack of assoc:%p is 0x%x, "
bb33381d0c97cde Daniel Borkmann    2013-06-28  1376  		 "advertised peer ack point:0x%x\n", __func__, asoc, ctsn,
bb33381d0c97cde Daniel Borkmann    2013-06-28  1377  		 asoc->adv_peer_ack_point);
^1da177e4c3f415 Linus Torvalds     2005-04-16  1378  
619a60ee04be332 Vlad Yasevich      2014-01-02  1379  	return sctp_outq_is_empty(q);
^1da177e4c3f415 Linus Torvalds     2005-04-16 @1380  }
^1da177e4c3f415 Linus Torvalds     2005-04-16  1381  

:::::: The code at line 1380 was first introduced by commit
:::::: 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 Linux-2.6.12-rc2

:::::: TO: Linus Torvalds <torvalds@...970.osdl.org>
:::::: CC: Linus Torvalds <torvalds@...970.osdl.org>

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

Download attachment ".config.gz" of type "application/gzip" (25994 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ