scsi: ufs-qcom: save ufs_qcom_host object pointers
Analyzing crash logs is made easier when the different UFS objects state is accessible. Save a pointer to the main ufs_qcom_host object when it is allocated. Change-Id: I8eb909729dee7209e5d9b1af2652fe76ccd3c0ca Signed-off-by: Gilad Broner <gbroner@codeaurora.org>
This commit is contained in:
parent
f3fdd87f21
commit
7223077cfd
2 changed files with 6 additions and 0 deletions
|
@ -35,6 +35,8 @@
|
||||||
#include "ufshci.h"
|
#include "ufshci.h"
|
||||||
#include "ufs-qcom-ice.h"
|
#include "ufs-qcom-ice.h"
|
||||||
|
|
||||||
|
static struct ufs_qcom_host *ufs_qcom_hosts[MAX_UFS_QCOM_HOSTS];
|
||||||
|
|
||||||
static void ufs_qcom_get_speed_mode(struct ufs_pa_layer_attr *p, char *result);
|
static void ufs_qcom_get_speed_mode(struct ufs_pa_layer_attr *p, char *result);
|
||||||
static int ufs_qcom_get_bus_vote(struct ufs_qcom_host *host,
|
static int ufs_qcom_get_bus_vote(struct ufs_qcom_host *host,
|
||||||
const char *speed_mode);
|
const char *speed_mode);
|
||||||
|
@ -1173,6 +1175,9 @@ static int ufs_qcom_init(struct ufs_hba *hba)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (hba->dev->id < MAX_UFS_QCOM_HOSTS)
|
||||||
|
ufs_qcom_hosts[hba->dev->id] = host;
|
||||||
|
|
||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
out_disable_phy:
|
out_disable_phy:
|
||||||
|
|
|
@ -16,6 +16,7 @@
|
||||||
|
|
||||||
#include <linux/phy/phy.h>
|
#include <linux/phy/phy.h>
|
||||||
|
|
||||||
|
#define MAX_UFS_QCOM_HOSTS 1
|
||||||
#define MAX_U32 (~(u32)0)
|
#define MAX_U32 (~(u32)0)
|
||||||
#define MPHY_TX_FSM_STATE 0x41
|
#define MPHY_TX_FSM_STATE 0x41
|
||||||
#define TX_FSM_HIBERN8 0x1
|
#define TX_FSM_HIBERN8 0x1
|
||||||
|
|
Loading…
Add table
Reference in a new issue