My Project
Enumerations | Functions

Enumerations

enum  kbase_mmu_fault_type {
  KBASE_MMU_FAULT_TYPE_UNKNOWN = 0, KBASE_MMU_FAULT_TYPE_PAGE, KBASE_MMU_FAULT_TYPE_BUS, KBASE_MMU_FAULT_TYPE_PAGE_UNEXPECTED,
  KBASE_MMU_FAULT_TYPE_BUS_UNEXPECTED
}
 MMU fault type descriptor.
 

Functions

void kbase_mmu_hw_configure (struct kbase_device *kbdev, struct kbase_as *as, struct kbase_context *kctx)
 Configure an address space for use. More...
 
int kbase_mmu_hw_do_operation (struct kbase_device *kbdev, struct kbase_as *as, struct kbase_context *kctx, u64 vpfn, u32 nr, u32 type, unsigned int handling_irq)
 Issue an operation to the MMU. More...
 
void kbase_mmu_hw_clear_fault (struct kbase_device *kbdev, struct kbase_as *as, struct kbase_context *kctx, enum kbase_mmu_fault_type type)
 Clear a fault that has been previously reported by the MMU. More...
 
void kbase_mmu_hw_enable_fault (struct kbase_device *kbdev, struct kbase_as *as, struct kbase_context *kctx, enum kbase_mmu_fault_type type)
 Enable fault that has been previously reported by the MMU. More...
 

Detailed Description

Function Documentation

◆ kbase_mmu_hw_clear_fault()

void kbase_mmu_hw_clear_fault ( struct kbase_device kbdev,
struct kbase_as as,
struct kbase_context kctx,
enum kbase_mmu_fault_type  type 
)

Clear a fault that has been previously reported by the MMU.

Clear a bus error or page fault that has been reported by the MMU.

Parameters
[in]kbdevkbase device to clear the fault from.
[in]asaddress space to clear the fault from.
[in]kctxkbase context to clear the fault from or NULL.
[in]typeThe type of fault that needs to be cleared.

◆ kbase_mmu_hw_configure()

void kbase_mmu_hw_configure ( struct kbase_device kbdev,
struct kbase_as as,
struct kbase_context kctx 
)

Configure an address space for use.

Configure the MMU using the address space details setup in the kbase_context structure.

Parameters
[in]kbdevkbase device to configure.
[in]asaddress space to configure.
[in]kctxkbase context to configure.

◆ kbase_mmu_hw_do_operation()

int kbase_mmu_hw_do_operation ( struct kbase_device kbdev,
struct kbase_as as,
struct kbase_context kctx,
u64  vpfn,
u32  nr,
u32  type,
unsigned int  handling_irq 
)

Issue an operation to the MMU.

Issue an operation (MMU invalidate, MMU flush, etc) on the address space that is associated with the provided kbase_context over the specified range

Parameters
[in]kbdevkbase device to issue the MMU operation on.
[in]asaddress space to issue the MMU operation on.
[in]kctxkbase context to issue the MMU operation on.
[in]vpfnMMU Virtual Page Frame Number to start the operation on.
[in]nrNumber of pages to work on.
[in]typeOperation type (written to ASn_COMMAND).
[in]handling_irqIs this operation being called during the handling of an interrupt?
Returns
Zero if the operation was successful, non-zero otherwise.

◆ kbase_mmu_hw_enable_fault()

void kbase_mmu_hw_enable_fault ( struct kbase_device kbdev,
struct kbase_as as,
struct kbase_context kctx,
enum kbase_mmu_fault_type  type 
)

Enable fault that has been previously reported by the MMU.

After a page fault or bus error has been reported by the MMU these will be disabled. After these are handled this function needs to be called to enable the page fault or bus error fault again.

Parameters
[in]kbdevkbase device to again enable the fault from.
[in]asaddress space to again enable the fault from.
[in]kctxkbase context to again enable the fault from.
[in]typeThe type of fault that needs to be enabled again.