tree: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git staging-testing head: e7b6875944e61bec586ede80b95727cd55381e1e commit: e7b6875944e61bec586ede80b95727cd55381e1e [41/41] Staging: vt6655: Replace camel case variable names. If you fix the issue, kindly add following tag as appropriate Reported-by: kbuild test robot <lkp@xxxxxxxxx> cppcheck warnings: (new ones prefixed by >>) >> drivers/staging/vt6655/baseband.c:1711:15: warning: The scope of the variable 'preamble' can be reduced. [variableScope] unsigned int preamble; ^ >> drivers/staging/vt6655/baseband.c:1912:16: warning: The scope of the variable 'by_value' can be reduced. [variableScope] >> unsigned char by_value; ^ drivers/staging/vt6655/baseband.c:1955:16: warning: The scope of the variable 'by_value' can be reduced. [variableScope] >> unsigned char by_value; ^ vim +/preamble +1711 drivers/staging/vt6655/baseband.c 1689 1690 /*--------------------- Export Variables --------------------------*/ 1691 /* 1692 * Description: Calculate data frame transmitting time 1693 * 1694 * Parameters: 1695 * In: 1696 * by_preamble_type - Preamble Type 1697 * by_pkt_type - PK_TYPE_11A, PK_TYPE_11B, PK_TYPE_11GB, PK_TYPE_11GA 1698 * cb_frame_length - Baseband Type 1699 * tx_rate - Tx Rate 1700 * Out: 1701 * 1702 * Return Value: FrameTime 1703 * 1704 */ 1705 unsigned int bb_get_frame_time(unsigned char by_preamble_type, 1706 unsigned char by_pkt_type, 1707 unsigned int cb_frame_length, 1708 unsigned short tx_rate) 1709 { 1710 unsigned int frame_time; > 1711 unsigned int preamble; 1712 unsigned int tmp; 1713 unsigned int rate_idx = (unsigned int)tx_rate; 1714 unsigned int rate = 0; 1715 1716 if (rate_idx > RATE_54M) 1717 return 0; 1718 1719 rate = (unsigned int)awcFrameTime[rate_idx]; 1720 1721 if (rate_idx <= 3) { /* CCK mode */ 1722 if (by_preamble_type == 1) /* Short */ 1723 preamble = 96; 1724 else 1725 preamble = 192; 1726 frame_time = (cb_frame_length * 80) / rate; /* ????? */ 1727 tmp = (frame_time * rate) / 80; 1728 if (cb_frame_length != tmp) 1729 frame_time++; 1730 1731 return preamble + frame_time; 1732 } 1733 frame_time = (cb_frame_length * 8 + 22) / rate; /* ???????? */ 1734 tmp = ((frame_time * rate) - 22) / 8; 1735 if (cb_frame_length != tmp) 1736 frame_time++; 1737 1738 frame_time = frame_time * 4; /* ??????? */ 1739 if (by_pkt_type != PK_TYPE_11A) 1740 frame_time += 6; /* ?????? */ 1741 1742 return 20 + frame_time; /* ?????? */ 1743 } 1744 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel