source: trunk/hal/x86_64/drivers/soclib_xcu.c @ 203

Last change on this file since 203 was 203, checked in by max@…, 7 years ago

start moving the APIC code into the PIC driver

File size: 2.2 KB
RevLine 
[75]1/*
[138]2 * soclib_xcu.c - x86 XCU driver API implementation.
[75]3 *
[138]4 * Copyright (c) 2017 Maxime Villard
[75]5 *
6 * This file is part of ALMOS-MKH.
7 *
[138]8 * ALMOS-MKH is free software; you can redistribute it and/or modify it
[75]9 * under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; version 2.0 of the License.
11 *
[138]12 * ALMOS-MKH is distributed in the hope that it will be useful, but
[75]13 * WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15 * General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
[138]18 * along with ALMOS-MKH.; if not, write to the Free Software Foundation,
[75]19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
20 */
21
22#include <soclib_xcu.h>
23#include <hal_types.h>
24#include <core.h>
25#include <chdev.h>
26
[135]27#include <hal_apic.h>
[138]28#include <hal_segmentation.h>
[129]29#include <hal_internal.h>
30
[135]31
32void soclib_xcu_init(chdev_t *icu, lid_t lid)
[75]33{
[129]34        x86_panic((char *)__func__);
[75]35}
36
[137]37void soclib_xcu_enable_irq(chdev_t *icu, uint32_t idx, uint32_t type,
38    lid_t lid)
[75]39{
[129]40        x86_panic((char *)__func__);
[75]41}
42
[137]43void soclib_xcu_disable_irq(chdev_t *icu, uint32_t idx, uint32_t type,
44    lid_t lid)
[75]45{
[129]46        x86_panic((char *)__func__);
[75]47}
48
[138]49void soclib_xcu_get_masks(chdev_t *icu, lid_t lid, uint32_t *hwi_mask,
50    uint32_t *wti_mask, uint32_t *pti_mask)
[75]51{
[129]52        x86_panic((char *)__func__);
[75]53}
54
55void soclib_xcu_set_period( chdev_t * icu,
56                            uint32_t  index,
57                            uint32_t  period )
58{
[129]59        x86_panic((char *)__func__);
[75]60}
61
62uint32_t soclib_xcu_ack_timer( chdev_t * icu,
63                               uint32_t  index )
64{
[129]65        x86_panic((char *)__func__);
[81]66        return 0;
[75]67}
68
[137]69void soclib_xcu_get_status(chdev_t *icu, lid_t lid, uint32_t *hwi_status,
70    uint32_t *wti_status, uint32_t *pti_status)
[75]71{
[137]72        if (lid != 0) {
73                x86_panic("xcu_get_status should have lid==0");
74        }
75
[129]76        x86_panic((char *)__func__);
[75]77}
78
79void soclib_xcu_send_ipi( xptr_t  icu_xp,
80                          lid_t   lid )
81{
[129]82        x86_panic((char *)__func__);
[75]83}
84
85uint32_t * soclib_xcu_wti_ptr( chdev_t  * icu,
86                               uint32_t   index )
87{
[129]88        x86_panic((char *)__func__);
[81]89        return NULL;
[75]90}
Note: See TracBrowser for help on using the repository browser.