mirror of
				https://review.coreboot.org/flashrom.git
				synced 2025-11-04 07:00:39 +01:00 
			
		
		
		
	Add ITE IT8720 SPI support
Original patch by Vadim Girlin. Message printing updated by Carl-Daniel Hailfinger. Corresponding to flashrom svn r989. Signed-off-by: Vadim Girlin <vadimgirlin@gmail.com> Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
This commit is contained in:
		
				
					committed by
					
						
						Carl-Daniel Hailfinger
					
				
			
			
				
	
			
			
			
						parent
						
							dfdc56f4a0
						
					
				
				
					commit
					957d260542
				
			@@ -103,6 +103,7 @@ static uint16_t find_ite_spi_flash_port(uint16_t port, uint16_t id)
 | 
				
			|||||||
	switch (id) {
 | 
						switch (id) {
 | 
				
			||||||
	case 0x8716:
 | 
						case 0x8716:
 | 
				
			||||||
	case 0x8718:
 | 
						case 0x8718:
 | 
				
			||||||
 | 
						case 0x8720:
 | 
				
			||||||
		enter_conf_mode_ite(port);
 | 
							enter_conf_mode_ite(port);
 | 
				
			||||||
		/* NOLDN, reg 0x24, mask out lowest bit (suspend) */
 | 
							/* NOLDN, reg 0x24, mask out lowest bit (suspend) */
 | 
				
			||||||
		tmp = sio_read(port, 0x24) & 0xFE;
 | 
							tmp = sio_read(port, 0x24) & 0xFE;
 | 
				
			||||||
@@ -159,7 +160,7 @@ static uint16_t find_ite_spi_flash_port(uint16_t port, uint16_t id)
 | 
				
			|||||||
		break;
 | 
							break;
 | 
				
			||||||
	/* TODO: Handle more IT87xx if they support flash translation */
 | 
						/* TODO: Handle more IT87xx if they support flash translation */
 | 
				
			||||||
	default:
 | 
						default:
 | 
				
			||||||
		msg_pinfo("SuperI/O ID %04hx is not on the controller list.\n", id);
 | 
							msg_pdbg("SuperI/O ID %04hx is not on the controller list.\n", id);
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
	return flashport;
 | 
						return flashport;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
@@ -199,8 +200,11 @@ int it87xx_probe_spi_flash(const char *name)
 | 
				
			|||||||
	int ret;
 | 
						int ret;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	ret = it87spi_common_init();
 | 
						ret = it87spi_common_init();
 | 
				
			||||||
	if (!ret)
 | 
						if (!ret) {
 | 
				
			||||||
 | 
							if (buses_supported & CHIP_BUSTYPE_SPI)
 | 
				
			||||||
 | 
								msg_pdbg("Overriding chipset SPI with IT87 SPI.\n");
 | 
				
			||||||
		buses_supported |= CHIP_BUSTYPE_SPI;
 | 
							buses_supported |= CHIP_BUSTYPE_SPI;
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
	return ret;
 | 
						return ret;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user