9
0
Fork 0

mci stmp378x: remove ifdefed code

There is no need to fill the FIFOs before starting a transfer, so
remove corresponding code which is commented out anyway. Additionally
this fixes a compiler warning with gcc4.5

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Jürgen Beisert <jbe@pengutronix.de>
This commit is contained in:
Sascha Hauer 2011-01-31 15:03:19 +01:00
parent 9e8dd8fd82
commit a4ad98bfa4
1 changed files with 2 additions and 19 deletions

View File

@ -351,25 +351,6 @@ static int write_data(struct device_d *hw_dev, const void *buffer, unsigned leng
*/
static int transfer_data(struct device_d *hw_dev, struct mci_data *data)
{
unsigned length;
if (data != NULL) {
length = data->blocks * data->blocksize;
#if 0
/*
* For the records: When writing data with high clock speeds it
* could be a good idea to fill the FIFO prior starting the
* transaction.
* But last time I tried it, it failed badly. Don't know why yet
*/
if (data->flags & MMC_DATA_WRITE) {
err = write_data(host, data->src, 16);
data->src += 16;
length -= 16;
}
#endif
}
/*
* Everything is ready for the transaction now:
* - transfer configuration
@ -380,6 +361,8 @@ static int transfer_data(struct device_d *hw_dev, struct mci_data *data)
writel(SSP_CTRL0_RUN, hw_dev->map_base + HW_SSP_CTRL0 + 4);
if (data != NULL) {
unsigned length = data->blocks * data->blocksize;
if (data->flags & MMC_DATA_READ)
return read_data(hw_dev, data->dest, length);
else