u-boot/drivers/net/fm
Masahiro Yamada b75d8dc564 treewide: convert bd_t to struct bd_info by coccinelle
The Linux coding style guide (Documentation/process/coding-style.rst)
clearly says:

  It's a **mistake** to use typedef for structures and pointers.

Besides, using typedef for structures is annoying when you try to make
headers self-contained.

Let's say you have the following function declaration in a header:

  void foo(bd_t *bd);

This is not self-contained since bd_t is not defined.

To tell the compiler what 'bd_t' is, you need to include <asm/u-boot.h>

  #include <asm/u-boot.h>
  void foo(bd_t *bd);

Then, the include direcective pulls in more bloat needlessly.

If you use 'struct bd_info' instead, it is enough to put a forward
declaration as follows:

  struct bd_info;
  void foo(struct bd_info *bd);

Right, typedef'ing bd_t is a mistake.

I used coccinelle to generate this commit.

The semantic patch that makes this change is as follows:

  <smpl>
  @@
  typedef bd_t;
  @@
  -bd_t
  +struct bd_info
  </smpl>

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2020-07-17 09:30:13 -04:00
..
b4860.c env: Move env_get_f() to env.h 2019-08-11 16:43:41 -04:00
dtsec.c common: Drop linux/delay.h from common header 2020-05-18 21:19:23 -04:00
eth.c treewide: convert bd_t to struct bd_info by coccinelle 2020-07-17 09:30:13 -04:00
fdt.c common: Drop image.h from common header 2020-05-18 17:33:33 -04:00
fm.c spi: Convert CONFIG_DM_SPI* to CONFIG_$(SPL_TPL_)DM_SPI* 2020-06-29 13:34:43 -04:00
fm.h driver: net: fm: add DM ETH support 2020-04-29 11:10:54 +05:30
init.c treewide: convert bd_t to struct bd_info by coccinelle 2020-07-17 09:30:13 -04:00
ls1043.c armv8/ls1043ardb: RGMII ports require internal delay 2020-03-30 08:06:52 +05:30
ls1046.c armv8/ls1046ardb: RGMII ports require internal delay 2020-03-30 08:06:52 +05:30
Makefile SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
memac.c common: Drop log.h from common header 2020-05-18 21:19:18 -04:00
memac_phy.c treewide: convert bd_t to struct bd_info by coccinelle 2020-07-17 09:30:13 -04:00
p1023.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
p4080.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
p5020.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
p5040.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
t1024.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
t1040.c powerpc: t1040: Correct RCW EC2 settings 2018-10-29 13:19:43 -07:00
t2080.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
t4240.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
tgec.c common: Drop linux/delay.h from common header 2020-05-18 21:19:23 -04:00
tgec_phy.c treewide: convert bd_t to struct bd_info by coccinelle 2020-07-17 09:30:13 -04:00