KallistiOS  ##version##
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
Macros | Functions
ubc.h File Reference

User-break controller support. More...

#include <sys/cdefs.h>
#include <arch/types.h>

Go to the source code of this file.

Macros

#define BARA   (*((vuint32*)0xFF200000))
 BARA register. More...
 
#define BASRA   (*((vuint8*)0xFF000014))
 BASRA register. More...
 
#define BAMRA   (*((vuint8*)0xFF200004))
 BAMRA register. More...
 
#define BBRA   (*((vuint16*)0xFF200008))
 BBRA register. More...
 
#define BARB   (*((vuint32*)0xFF20000C))
 BARB register. More...
 
#define BASRB   (*((vuint8*)0xFF000018))
 BASRB register. More...
 
#define BAMRB   (*((vuint8*)0xFF200010))
 BAMRB register. More...
 
#define BBRB   (*((vuint16*)0xFF200014))
 BBRB register. More...
 
#define BRCR   (*((vuint16*)0xFF200020))
 BRCR register. More...
 

Functions

static void ubc_pause ()
 Pause after setting UBC parameters. More...
 
static void ubc_disable_all ()
 Disable all UBC breakpoints. More...
 
static void ubc_break_data_write (uint32 address)
 Set a UBC data-write breakpoint at the given address. More...
 
static void ubc_break_inst (uint32 address, int use_dbr)
 Set a UBC instruction access breakpoint at the given address. More...
 

Detailed Description

User-break controller support.

This file defines some functionality for using the SH4 UBC.

Author
Dan Potter

Function Documentation

static void ubc_break_data_write ( uint32  address)
inlinestatic

Set a UBC data-write breakpoint at the given address.

Parameters
addressThe address to set the breakpoint at

References BAMRA, BARA, BASRA, BBRA, BRCR, and ubc_pause().

static void ubc_break_inst ( uint32  address,
int  use_dbr 
)
inlinestatic

Set a UBC instruction access breakpoint at the given address.

Parameters
addressThe address to set the breakpoint at.
use_dbrUse the DBR register as the base for the exception.

References BAMRA, BARA, BASRA, BBRA, BRCR, and ubc_pause().

static void ubc_disable_all ( )
inlinestatic

Disable all UBC breakpoints.

References BBRA, BBRB, and ubc_pause().

static void ubc_pause ( )
inlinestatic

Pause after setting UBC parameters.

Referenced by ubc_break_data_write(), ubc_break_inst(), and ubc_disable_all().