Commit 9e75963a authored by Ondrej Zary's avatar Ondrej Zary Committed by Damien Le Moal

ata: pata_parport-bpck6: move ppc6_wr_extout to bpck6.c and rename

Move ppc6_wr_extout to bpck6.c and rename it to bpck6_wr_extout
Signed-off-by: default avatarOndrej Zary <linux@zary.sk>
Signed-off-by: default avatarDamien Le Moal <damien.lemoal@opensource.wdc.com>
parent 144e7799
......@@ -174,18 +174,24 @@ static void bpck6_read_block(struct pi_adapter *pi, char *buf, int len)
ppc6_send_cmd(pi, CMD_PREFIX_RESET | PREFIX_IO16 | PREFIX_BLK);
}
static void bpck6_wr_extout(struct pi_adapter *pi, u8 regdata)
{
ppc6_send_cmd(pi, REG_VERSION | ACCESS_REG | ACCESS_WRITE);
ppc6_wr_data_byte(pi, (u8)((regdata & 0x03) << 6));
}
static void bpck6_connect(struct pi_adapter *pi)
{
dev_dbg(&pi->dev, "connect\n");
ppc6_open(pi);
ppc6_wr_extout(pi, 0x3);
bpck6_wr_extout(pi, 0x3);
}
static void bpck6_disconnect(struct pi_adapter *pi)
{
dev_dbg(&pi->dev, "disconnect\n");
ppc6_wr_extout(pi, 0x0);
bpck6_wr_extout(pi, 0x0);
ppc6_deselect(pi);
}
......
......@@ -72,7 +72,6 @@ static void ppc6_deselect(struct pi_adapter *pi);
static void ppc6_send_cmd(struct pi_adapter *pi, u8 cmd);
static void ppc6_wr_data_byte(struct pi_adapter *pi, u8 data);
static u8 ppc6_rd_data_byte(struct pi_adapter *pi);
static void ppc6_wr_extout(struct pi_adapter *pi, u8 regdata);
static int ppc6_open(struct pi_adapter *pi);
//***************************************************************************
......@@ -281,15 +280,6 @@ static u8 ppc6_rd_data_byte(struct pi_adapter *pi)
//***************************************************************************
static void ppc6_wr_extout(struct pi_adapter *pi, u8 regdata)
{
ppc6_send_cmd(pi, REG_VERSION | ACCESS_REG | ACCESS_WRITE);
ppc6_wr_data_byte(pi, (u8)((regdata & 0x03) << 6));
}
//***************************************************************************
static int ppc6_open(struct pi_adapter *pi)
{
int ret;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment