Lines Matching refs:msh
365 static int jmb38x_ms_issue_cmd(struct memstick_host *msh) in jmb38x_ms_issue_cmd() argument
367 struct jmb38x_ms_host *host = memstick_priv(msh); in jmb38x_ms_issue_cmd()
372 dev_dbg(&msh->dev, "no media status\n"); in jmb38x_ms_issue_cmd()
377 dev_dbg(&msh->dev, "control %08x\n", readl(host->addr + HOST_CONTROL)); in jmb38x_ms_issue_cmd()
378 dev_dbg(&msh->dev, "status %08x\n", readl(host->addr + INT_STATUS)); in jmb38x_ms_issue_cmd()
379 dev_dbg(&msh->dev, "hstatus %08x\n", readl(host->addr + STATUS)); in jmb38x_ms_issue_cmd()
458 dev_dbg(&msh->dev, "executing TPC %08x, len %x\n", cmd, data_len); in jmb38x_ms_issue_cmd()
463 static void jmb38x_ms_complete_cmd(struct memstick_host *msh, int last) in jmb38x_ms_complete_cmd() argument
465 struct jmb38x_ms_host *host = memstick_priv(msh); in jmb38x_ms_complete_cmd()
471 dev_dbg(&msh->dev, "c control %08x\n", in jmb38x_ms_complete_cmd()
473 dev_dbg(&msh->dev, "c status %08x\n", in jmb38x_ms_complete_cmd()
475 dev_dbg(&msh->dev, "c hstatus %08x\n", readl(host->addr + STATUS)); in jmb38x_ms_complete_cmd()
502 rc = memstick_next_req(msh, &host->req); in jmb38x_ms_complete_cmd()
503 } while (!rc && jmb38x_ms_issue_cmd(msh)); in jmb38x_ms_complete_cmd()
506 rc = memstick_next_req(msh, &host->req); in jmb38x_ms_complete_cmd()
515 struct memstick_host *msh = dev_id; in jmb38x_ms_isr() local
516 struct jmb38x_ms_host *host = memstick_priv(msh); in jmb38x_ms_isr()
570 memstick_detect_change(msh); in jmb38x_ms_isr()
579 jmb38x_ms_complete_cmd(msh, 0); in jmb38x_ms_isr()
587 struct memstick_host *msh = (struct memstick_host *)data; in jmb38x_ms_abort() local
588 struct jmb38x_ms_host *host = memstick_priv(msh); in jmb38x_ms_abort()
595 jmb38x_ms_complete_cmd(msh, 0); in jmb38x_ms_abort()
602 struct memstick_host *msh = (struct memstick_host *)data; in jmb38x_ms_req_tasklet() local
603 struct jmb38x_ms_host *host = memstick_priv(msh); in jmb38x_ms_req_tasklet()
610 rc = memstick_next_req(msh, &host->req); in jmb38x_ms_req_tasklet()
612 } while (!rc && jmb38x_ms_issue_cmd(msh)); in jmb38x_ms_req_tasklet()
617 static void jmb38x_ms_dummy_submit(struct memstick_host *msh) in jmb38x_ms_dummy_submit() argument
622 static void jmb38x_ms_submit_req(struct memstick_host *msh) in jmb38x_ms_submit_req() argument
624 struct jmb38x_ms_host *host = memstick_priv(msh); in jmb38x_ms_submit_req()
671 static int jmb38x_ms_set_param(struct memstick_host *msh, in jmb38x_ms_set_param() argument
675 struct jmb38x_ms_host *host = memstick_priv(msh); in jmb38x_ms_set_param()
824 struct memstick_host *msh; in jmb38x_ms_alloc_host() local
827 msh = memstick_alloc_host(sizeof(struct jmb38x_ms_host), in jmb38x_ms_alloc_host()
829 if (!msh) in jmb38x_ms_alloc_host()
832 host = memstick_priv(msh); in jmb38x_ms_alloc_host()
846 tasklet_init(&host->notify, jmb38x_ms_req_tasklet, (unsigned long)msh); in jmb38x_ms_alloc_host()
847 msh->request = jmb38x_ms_submit_req; in jmb38x_ms_alloc_host()
848 msh->set_param = jmb38x_ms_set_param; in jmb38x_ms_alloc_host()
850 msh->caps = MEMSTICK_CAP_PAR4 | MEMSTICK_CAP_PAR8; in jmb38x_ms_alloc_host()
852 setup_timer(&host->timer, jmb38x_ms_abort, (unsigned long)msh); in jmb38x_ms_alloc_host()
855 msh)) in jmb38x_ms_alloc_host()
856 return msh; in jmb38x_ms_alloc_host()
860 kfree(msh); in jmb38x_ms_alloc_host()
864 static void jmb38x_ms_free_host(struct memstick_host *msh) in jmb38x_ms_free_host() argument
866 struct jmb38x_ms_host *host = memstick_priv(msh); in jmb38x_ms_free_host()
868 free_irq(host->irq, msh); in jmb38x_ms_free_host()
870 memstick_free_host(msh); in jmb38x_ms_free_host()