Date: Sat, 3 Oct 2009 17:49:44 +0000 (UTC) From: Rui Paulo <rpaulo@FreeBSD.org> To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r197737 - user/rpaulo/armpmc/dev/hwpmc Message-ID: <200910031749.n93Hnilv047363@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: rpaulo Date: Sat Oct 3 17:49:44 2009 New Revision: 197737 URL: http://svn.freebsd.org/changeset/base/197737 Log: Checkpoint code. It no longer panics. Modified: user/rpaulo/armpmc/dev/hwpmc/hwpmc_xscale.c Modified: user/rpaulo/armpmc/dev/hwpmc/hwpmc_xscale.c ============================================================================== --- user/rpaulo/armpmc/dev/hwpmc/hwpmc_xscale.c Sat Oct 3 16:13:56 2009 (r197736) +++ user/rpaulo/armpmc/dev/hwpmc/hwpmc_xscale.c Sat Oct 3 17:49:44 2009 (r197737) @@ -45,47 +45,68 @@ struct xscale_event_code_map { static int xscale_read_pmc(int cpu, int ri, pmc_value_t *v) { + return 0; } static int xscale_write_pmc(int cpu, int ri, pmc_value_t v) { + return 0; } static int xscale_config_pmc(int cpu, int ri, struct pmc *pm) { + return 0; } static int xscale_start_pmc(int cpu, int ri) { + return 0; } static int xscale_stop_pmc(int cpu, int ri) { + return 0; } static int xscale_intr(int cpu, struct trapframe *tf) { + return 0; } static int xscale_describe(int cpu, int ri, struct pmc_info *pi, struct pmc **ppmc) { + return 0; +} + +static int +xscale_pcpu_init(struct pmc_mdep *md, int cpu) +{ + return 0; +} + +static int +xscale_pcpu_fini(struct pmc_mdep *md, int cpu) +{ + return 0; } struct pmc_mdep * pmc_xscale_initialize() { struct pmc_mdep *pmc_mdep; + struct pmc_classdep *pcd; pmc_mdep = malloc(sizeof(struct pmc_mdep) + sizeof(struct pmc_classdep), M_PMC, M_WAITOK|M_ZERO); pmc_mdep->pmd_cputype = PMC_CPU_INTEL_XSCALE; pmc_mdep->pmd_nclass = 1; + pmc_mdep->pmd_npmc = XSCALE_NPMCS; pcd = &pmc_mdep->pmd_classdep[0]; pcd->pcd_caps = XSCALE_PMC_CAPS; @@ -93,19 +114,21 @@ pmc_xscale_initialize() pcd->pcd_ri = pmc_mdep->pmd_npmc; pcd->pcd_width = 48; /* XXX */ - pcd->pcd_allocate_pmc = xscale_allocate_pmc; + //pcd->pcd_allocate_pmc = xscale_allocate_pmc; pcd->pcd_config_pmc = xscale_config_pmc; + pcd->pcd_pcpu_fini = xscale_pcpu_fini; + pcd->pcd_pcpu_init = xscale_pcpu_init; pcd->pcd_describe = xscale_describe; - pcd->pcd_get_config = xscale_get_config; + //pcd->pcd_get_config = xscale_get_config; pcd->pcd_read_pmc = xscale_read_pmc; - pcd->pcd_release_pmc = xscale_release_pmc; + //pcd->pcd_release_pmc = xscale_release_pmc; pcd->pcd_start_pmc = xscale_start_pmc; pcd->pcd_stop_pmc = xscale_stop_pmc; pcd->pcd_write_pmc = xscale_write_pmc; pmc_mdep->pmd_intr = xscale_intr; - pmc_mdep->pmd_switch_in = xscale_switch_in; - pmc_mdep->pmd_switch_out = xscale_switch_out; + //pmc_mdep->pmd_switch_in = xscale_switch_in; + //pmc_mdep->pmd_switch_out = xscale_switch_out; return (pmc_mdep); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200910031749.n93Hnilv047363>