Remove leftover tseg_relocate

Change-Id: I534f992ed479c7cdc049bd598259b1f1cf2953b9
Signed-off-by: Vladimir Serbinenko <phcoder@gmail.com>
Reviewed-on: http://review.coreboot.org/10354
Tested-by: build bot (Jenkins)
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
This commit is contained in:
Vladimir Serbinenko 2015-05-28 21:06:24 +02:00
parent 7f46420f4c
commit beb45020ac
2 changed files with 0 additions and 21 deletions

View File

@ -349,10 +349,6 @@ struct spi_flash *spi_flash_probe(unsigned int bus, unsigned int cs)
/* search the table for matches in shift and id */ /* search the table for matches in shift and id */
for (i = 0; i < ARRAY_SIZE(flashes); ++i) for (i = 0; i < ARRAY_SIZE(flashes); ++i)
if (flashes[i].shift == shift && flashes[i].idcode == *idp) { if (flashes[i].shift == shift && flashes[i].idcode == *idp) {
#if CONFIG_SMM_TSEG && defined(__SMM__)
/* Need to relocate this function */
tseg_relocate((void **)&flashes[i].probe);
#endif
/* we have a match, call probe */ /* we have a match, call probe */
flash = flashes[i].probe(spi, idp); flash = flashes[i].probe(spi, idp);
if (flash) if (flash)
@ -360,10 +356,6 @@ struct spi_flash *spi_flash_probe(unsigned int bus, unsigned int cs)
} }
if (!flash && spi->programmer_specific_probe) { if (!flash && spi->programmer_specific_probe) {
#if CONFIG_SMM_TSEG && defined(__SMM__)
/* Need to relocate this function */
tseg_relocate((void **)&spi->programmer_specific_probe);
#endif
flash = spi->programmer_specific_probe (spi); flash = spi->programmer_specific_probe (spi);
} }
if (!flash) { if (!flash) {
@ -372,15 +364,6 @@ struct spi_flash *spi_flash_probe(unsigned int bus, unsigned int cs)
} }
flash_detected: flash_detected:
#if CONFIG_SMM_TSEG && defined(__SMM__)
/* Ensure flash handlers are valid for TSEG */
tseg_relocate((void **)&flash->read);
tseg_relocate((void **)&flash->write);
tseg_relocate((void **)&flash->erase);
tseg_relocate((void **)&flash->status);
tseg_relocate((void **)&flash->name);
#endif
printk(BIOS_INFO, "SF: Detected %s with sector size 0x%x, total 0x%x\n", printk(BIOS_INFO, "SF: Detected %s with sector size 0x%x, total 0x%x\n",
flash->name, flash->sector_size, flash->size); flash->name, flash->sector_size, flash->size);

View File

@ -487,15 +487,11 @@ void mainboard_smi_sleep(u8 slp_typ);
#if !CONFIG_SMM_TSEG #if !CONFIG_SMM_TSEG
void smi_release_lock(void); void smi_release_lock(void);
#define tseg_relocate(ptr)
#elif CONFIG_SMM_MODULES #elif CONFIG_SMM_MODULES
#define tseg_relocate(ptr)
#define smi_get_tseg_base() 0 #define smi_get_tseg_base() 0
#else #else
/* Return address of TSEG base */ /* Return address of TSEG base */
u32 smi_get_tseg_base(void); u32 smi_get_tseg_base(void);
/* Adjust pointer with TSEG base */
void tseg_relocate(void **ptr);
#endif #endif
/* Get PMBASE address */ /* Get PMBASE address */