参考这里:
http://e2e.ti.com/support/arm/sitara_arm/f/791/t/168122.aspx
http://*code.co.uk/blog/blogPost.php?blogPostID=1
linuxkernelpsp/arch/arm/mach-omap2/board-am335xevm.c:
找到 vm_dev_cfg beaglebone_dev_cfg
加入
{spi1_init, DEV_ON_BASEBOARD, PROFILE_ALL},
找到 spi_board_info am335x_spi0_slave_info
把"m25p80" 改成spidev
static struct spi_board_info am335x_spi1_slave_info[] = {
{
.modalias = "spidev",
.platform_data = &am335x_spi_flash,
.irq = -1,
.max_speed_hz = 10000000,
.bus_num = 2,
.chip_select = 0,
.mode = SPI_MODE_0,
},
};