u8 aux_lut_cfg_index[PHY_AUX_CFG_MAX];
};
+void dp_catalog_snapshot(struct dp_catalog *dp_catalog, struct msm_disp_state *disp_state)
+{
+ struct dp_catalog_private *catalog = container_of(dp_catalog,
+ struct dp_catalog_private, dp_catalog);
+
+ msm_disp_snapshot_add_block(disp_state, catalog->io->dp_controller.len,
+ catalog->io->dp_controller.base, "dp_ctrl");
+}
+
static inline u32 dp_read_aux(struct dp_catalog_private *catalog, u32 offset)
{
offset += MSM_DP_CONTROLLER_AUX_OFFSET;
#include <drm/drm_modes.h>
#include "dp_parser.h"
+#include "disp/msm_disp_snapshot.h"
/* interrupts */
#define DP_INTR_HPD BIT(0)
u32 audio_data;
};
+/* Debug module */
+void dp_catalog_snapshot(struct dp_catalog *dp_catalog, struct msm_disp_state *disp_state);
+
/* AUX APIs */
u32 dp_catalog_aux_read_data(struct dp_catalog *dp_catalog);
int dp_catalog_aux_write_data(struct dp_catalog *dp_catalog);
dp_display->link->test_video.test_bit_depth);
}
+void msm_dp_snapshot(struct msm_dp *dp)
+{
+ struct dp_display_private *dp_display;
+ struct drm_device *drm;
+ struct msm_disp_state *disp_state;
+
+ dp_display = container_of(dp, struct dp_display_private, dp_display);
+ drm = dp->drm_dev;
+ disp_state = msm_disp_state_get(drm);
+
+ /*
+ * if we are reading registers we need the link clocks to be on
+ * however till DP cable is connected this will not happen as we
+ * do not know the resolution to power up with. Hence check the
+ * power_on status before dumping DP registers to avoid crash due
+ * to unclocked access
+ */
+ mutex_lock(&dp_display->event_mutex);
+
+ if (!dp->power_on) {
+ mutex_unlock(&dp_display->event_mutex);
+ return;
+ }
+
+ dp_catalog_snapshot(dp_display->catalog, disp_state);
+
+ mutex_unlock(&dp_display->event_mutex);
+}
+
static void dp_display_config_hpd(struct dp_display_private *dp)
{
struct drm_display_mode *mode,
struct drm_display_mode *adjusted_mode);
void msm_dp_irq_postinstall(struct msm_dp *dp_display);
+void msm_dp_snapshot(struct msm_dp *dp_display);
void msm_dp_debugfs_init(struct msm_dp *dp_display, struct drm_minor *minor);