linux/drivers/staging/rts5208/rtsx_chip.c

// SPDX-License-Identifier: GPL-2.0+
/*
 * Driver for Realtek PCI-Express card reader
 *
 * Copyright(c) 2009-2013 Realtek Semiconductor Corp. All rights reserved.
 *
 * Author:
 *   Wei WANG ([email protected])
 *   Micky Ching ([email protected])
 */

#include <linux/blkdev.h>
#include <linux/kthread.h>
#include <linux/sched.h>
#include <linux/workqueue.h>
#include <linux/vmalloc.h>

#include "rtsx.h"
#include "sd.h"
#include "xd.h"
#include "ms.h"

static void rtsx_calibration(struct rtsx_chip *chip)
{}

void rtsx_enable_card_int(struct rtsx_chip *chip)
{}

void rtsx_enable_bus_int(struct rtsx_chip *chip)
{}

void rtsx_disable_bus_int(struct rtsx_chip *chip)
{}

static int rtsx_pre_handle_sdio_old(struct rtsx_chip *chip)
{}

#ifdef HW_AUTO_SWITCH_SD_BUS
static int rtsx_pre_handle_sdio_new(struct rtsx_chip *chip)
{}
#endif

static int rtsx_reset_aspm(struct rtsx_chip *chip)
{}

static int rtsx_enable_pcie_intr(struct rtsx_chip *chip)
{}

int rtsx_reset_chip(struct rtsx_chip *chip)
{}

static inline int valid_sd_speed_prior(u32 sd_speed_prior)
{}

static inline int valid_sd_current_prior(u32 sd_current_prior)
{}

static int rts5208_init(struct rtsx_chip *chip)
{}

static int rts5288_init(struct rtsx_chip *chip)
{}

int rtsx_init_chip(struct rtsx_chip *chip)
{}

void rtsx_release_chip(struct rtsx_chip *chip)
{}

#if !defined(LED_AUTO_BLINK) && defined(REGULAR_BLINK)
static inline void rtsx_blink_led(struct rtsx_chip *chip)
{}
#endif

static void rtsx_monitor_aspm_config(struct rtsx_chip *chip)
{}

static void rtsx_manage_ocp(struct rtsx_chip *chip)
{}

static void rtsx_manage_sd_lock(struct rtsx_chip *chip)
{}

static bool rtsx_is_ss_allowed(struct rtsx_chip *chip)
{}

static void rtsx_manage_ss(struct rtsx_chip *chip)
{}

static void rtsx_manage_aspm(struct rtsx_chip *chip)
{}

static void rtsx_manage_idle(struct rtsx_chip *chip)
{}

static void rtsx_manage_2lun_mode(struct rtsx_chip *chip)
{}

static void rtsx_manage_1lun_mode(struct rtsx_chip *chip)
{}

static void rtsx_delink_stage1(struct rtsx_chip *chip, int enter_L1,
			       int stage3_cnt)
{}

static void rtsx_delink_stage(struct rtsx_chip *chip)
{}

void rtsx_polling_func(struct rtsx_chip *chip)
{}

/**
 * rtsx_stop_cmd - stop command transfer and DMA transfer
 * @chip: Realtek's card reader chip
 * @card: flash card type
 *
 * Stop command transfer and DMA transfer.
 * This function is called in error handler.
 */
void rtsx_stop_cmd(struct rtsx_chip *chip, int card)
{}

#define MAX_RW_REG_CNT

int rtsx_write_register(struct rtsx_chip *chip, u16 addr, u8 mask, u8 data)
{}

int rtsx_read_register(struct rtsx_chip *chip, u16 addr, u8 *data)
{}

int rtsx_write_cfg_dw(struct rtsx_chip *chip, u8 func_no, u16 addr, u32 mask,
		      u32 val)
{}

int rtsx_read_cfg_dw(struct rtsx_chip *chip, u8 func_no, u16 addr, u32 *val)
{}

int rtsx_write_cfg_seq(struct rtsx_chip *chip, u8 func, u16 addr, u8 *buf,
		       int len)
{}

int rtsx_read_cfg_seq(struct rtsx_chip *chip, u8 func, u16 addr, u8 *buf,
		      int len)
{}

int rtsx_write_phy_register(struct rtsx_chip *chip, u8 addr, u16 val)
{}

int rtsx_read_phy_register(struct rtsx_chip *chip, u8 addr, u16 *val)
{}

int rtsx_read_efuse(struct rtsx_chip *chip, u8 addr, u8 *val)
{}

int rtsx_write_efuse(struct rtsx_chip *chip, u8 addr, u8 val)
{}

int rtsx_clr_phy_reg_bit(struct rtsx_chip *chip, u8 reg, u8 bit)
{}

int rtsx_set_phy_reg_bit(struct rtsx_chip *chip, u8 reg, u8 bit)
{}

static void rtsx_handle_pm_dstate(struct rtsx_chip *chip, u8 dstate)
{}

void rtsx_enter_L1(struct rtsx_chip *chip)
{}

void rtsx_exit_L1(struct rtsx_chip *chip)
{}

void rtsx_enter_ss(struct rtsx_chip *chip)
{}

void rtsx_exit_ss(struct rtsx_chip *chip)
{}

int rtsx_pre_handle_interrupt(struct rtsx_chip *chip)
{}

void rtsx_do_before_power_down(struct rtsx_chip *chip, int pm_stat)
{}

void rtsx_enable_aspm(struct rtsx_chip *chip)
{}

void rtsx_disable_aspm(struct rtsx_chip *chip)
{}

int rtsx_read_ppbuf(struct rtsx_chip *chip, u8 *buf, int buf_len)
{}

int rtsx_write_ppbuf(struct rtsx_chip *chip, u8 *buf, int buf_len)
{}

int rtsx_check_chip_exist(struct rtsx_chip *chip)
{}

int rtsx_force_power_on(struct rtsx_chip *chip, u8 ctl)
{}

int rtsx_force_power_down(struct rtsx_chip *chip, u8 ctl)
{}