• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/components/opensource/linux/linux-2.6.36/drivers/net/wan/

Lines Matching refs:hw

69 static int load_cyc2x(struct cycx_hw *hw, struct cycx_firmware *cfm, u32 len);
70 static void cycx_bootcfg(struct cycx_hw *hw);
136 int cycx_setup(struct cycx_hw *hw, void *cfm, u32 len, unsigned long dpmbase)
141 if (!get_option_index(cycx_2x_irq_options, hw->irq)) {
142 printk(KERN_ERR "%s: IRQ %d is invalid!\n", modname, hw->irq);
157 hw->dpmbase = ioremap(dpmbase, CYCX_WINDOWSIZE);
158 hw->dpmsize = CYCX_WINDOWSIZE;
160 if (!detect_cyc2x(hw->dpmbase)) {
170 err = load_cyc2x(hw, cfm, len);
173 cycx_down(hw); /* shutdown adapter */
179 int cycx_down(struct cycx_hw *hw)
181 iounmap(hw->dpmbase);
186 static void cycx_inten(struct cycx_hw *hw)
188 writeb(0, hw->dpmbase);
193 void cycx_intr(struct cycx_hw *hw)
195 writew(0, hw->dpmbase + GEN_CYCX_INTR);
220 int cycx_peek(struct cycx_hw *hw, u32 addr, void *buf, u32 len)
223 *(u8*)buf = readb(hw->dpmbase + addr);
225 memcpy_fromio(buf, hw->dpmbase + addr, len);
233 int cycx_poke(struct cycx_hw *hw, u32 addr, void *buf, u32 len)
236 writeb(*(u8*)buf, hw->dpmbase + addr);
238 memcpy_toio(hw->dpmbase + addr, buf, len);
382 static int load_cyc2x(struct cycx_hw *hw, struct cycx_firmware *cfm, u32 len)
389 void __iomem *pt_cycld = hw->dpmbase + 0x400;
447 if (!reset_cyc2x(hw->dpmbase)) {
454 cycx_reset_boot(hw->dpmbase, reset_image, img_hdr->reset_size);
471 if (cycx_data_boot(hw->dpmbase, data_image, img_hdr->data_size)) {
477 if (cycx_code_boot(hw->dpmbase, code_image, img_hdr->code_size)) {
483 cycx_bootcfg(hw);
486 cycx_start(hw->dpmbase);
494 cycx_inten(hw);
505 static void cycx_bootcfg(struct cycx_hw *hw)
508 writeb(FIXED_BUFFERS, hw->dpmbase + CONF_OFFSET);