PSOC E8XXGP Device Support Library

| PSOC E8XXGP Device Support Library

Functions
Functions
PDL API Reference » MS_CTL (Master Security Controller)

## General Description

## Functions
cy_en_ms_ctl_status_t | Cy_Ms_Ctl_ConfigBusMaster (en_ms_ctl_master_t busMaster, bool privileged, bool nonSecure, uint32_t pcMask)
| Configures the referenced bus master by setting the privilege , non-secure and protection context (PC) mask settings. More...
cy_en_ms_ctl_status_t | Cy_Ms_Ctl_ConfigMscAcgResp (en_ms_ctl_master_sc_acg_t busMaster, cy_en_ms_ctl_cfg_gate_resp_t gateResp, cy_en_ms_ctl_sec_resp_t secResp)
| Response configuration for ACG and MSC for the referenced bus master. More...
cy_en_ms_ctl_status_t | Cy_Ms_Ctl_SetPcHandler (uint32_t pc, cy_israddress handler)
| Sets the handler address for the given PC. More...
__STATIC_INLINE cy_en_ms_ctl_status_t | Cy_Ms_Ctl_SetActivePC (en_ms_ctl_master_t busMaster, uint32_t pc)
| Set active protection context (PC) for the referenced bus master. More...
__STATIC_INLINE uint32_t | Cy_Ms_Ctl_GetActivePC (en_ms_ctl_master_t busMaster)
| Reads the active protection context (PC) for the referenced bus master. More...
__STATIC_INLINE cy_en_ms_ctl_status_t | Cy_Ms_Ctl_SetSavedPC (en_ms_ctl_master_t busMaster, uint32_t savedPc)
| Set saved protection context (PC) for the referenced bus master. More...
__STATIC_INLINE uint32_t | Cy_Ms_Ctl_GetSavedPC (en_ms_ctl_master_t busMaster)
| Reads the saved protection context (PC) for the referenced bus master. More...
cy_israddress | Cy_Ms_Ctl_GetPcHandler (uint32_t pc)
| Reads the handler address for the given PC. More...
cy_en_ms_ctl_status_t | Cy_Ms_Ctl_ConfigBusMasterV1 (en_ms_ctl_master_t busMaster, bool privileged, bool nonSecure, uint32_t pcMask)
| Configures the referenced bus master by setting the privilege, non-secure and protection context (PC) mask settings in APPCPUSS. More...
cy_en_ms_ctl_status_t | Cy_Ms_Ctl_ConfigMscAcgRespV1 (en_ms_ctl_master_sc_acg_v1_t busMaster, cy_en_ms_ctl_cfg_gate_resp_t gateResp, cy_en_ms_ctl_sec_resp_t secResp)
| Response configuration for ACG and MSC for the referenced bus master in APPCPUSS. More...
__STATIC_INLINE cy_en_ms_ctl_status_t | Cy_Ms_Ctl_SetActivePCV1 (en_ms_ctl_master_t busMaster, uint32_t pc)
| Set active protection context (PCTX) for the referenced bus master in APPCPUSS. More...
__STATIC_INLINE uint32_t | Cy_Ms_Ctl_GetActivePCV1 (en_ms_ctl_master_t busMaster)
| Reads the active protection context (PCTX) for the referenced bus master in APPCPUSS. More...

## Function Documentation

## ◆ Cy_Ms_Ctl_ConfigBusMaster()

cy_en_ms_ctl_status_t Cy_Ms_Ctl_ConfigBusMaster | ( | en_ms_ctl_master_t | busMaster,
|  | bool | privileged,
|  | bool | nonSecure,
|  | uint32_t | pcMask
| ) |  |

Configures the referenced bus master by setting the privilege , non-secure and protection context (PC) mask settings.

Parameters

  busMaster | Bus master being initialized
  privileged | privileged setting, 'false': user mode; 'true': privileged mode
  pcMask | pcMask
  nonSecure | Bus master security setting, 'false': secure; 'true': non-secure

Returns
  Requested operation status

## ◆ Cy_Ms_Ctl_ConfigMscAcgResp()

cy_en_ms_ctl_status_t Cy_Ms_Ctl_ConfigMscAcgResp | ( | en_ms_ctl_master_sc_acg_t | busMaster,
|  | cy_en_ms_ctl_cfg_gate_resp_t | gateResp,
|  | cy_en_ms_ctl_sec_resp_t | secResp
| ) |  |

Response configuration for ACG and MSC for the referenced bus master.

Parameters

  busMaster | Bus master for which response is being initialized
  gateResp | Response type when the ACG is blocking the incoming transfers:
  secResp | Bust master privileged setting

Returns
  Requested operation status

## ◆ Cy_Ms_Ctl_SetPcHandler()

cy_en_ms_ctl_status_t Cy_Ms_Ctl_SetPcHandler | ( | uint32_t | pc,
|  | cy_israddress | handler
| ) |  |

Sets the handler address for the given PC.

This is used to detect entry to "trusted" code through an exception/interrupt.

Note
  The function can't update the handler address for the PC lower than the current application's PC. For example, if the application is running in PC2 it can't update handler address for PC0 or PC1.

Parameters

  pc | Protection context for which the handler is being set
  handler | Address of the protection context handler

Returns
  Requested operation status

## ◆ Cy_Ms_Ctl_SetActivePC()

__STATIC_INLINE cy_en_ms_ctl_status_t Cy_Ms_Ctl_SetActivePC | ( | en_ms_ctl_master_t | busMaster,
|  | uint32_t | pc
| ) |  |

Set active protection context (PC) for the referenced bus master.

Parameters

  busMaster | Bus master being initialized
  pc | Protection Context value

Returns
  Requested operation status

## ◆ Cy_Ms_Ctl_GetActivePC()

__STATIC_INLINE uint32_t Cy_Ms_Ctl_GetActivePC | ( | en_ms_ctl_master_t | busMaster | ) |

Reads the active protection context (PC) for the referenced bus master.

Parameters

  busMaster | Bus master for which the PC value is being read

Returns
  Protection Context value

## ◆ Cy_Ms_Ctl_SetSavedPC()

__STATIC_INLINE cy_en_ms_ctl_status_t Cy_Ms_Ctl_SetSavedPC | ( | en_ms_ctl_master_t | busMaster,
|  | uint32_t | savedPc
| ) |  |

Set saved protection context (PC) for the referenced bus master.

Parameters

  busMaster | Bus master being initialized
  savedPc | Protection Context value

Returns
  Requested operation status

## ◆ Cy_Ms_Ctl_GetSavedPC()

__STATIC_INLINE uint32_t Cy_Ms_Ctl_GetSavedPC | ( | en_ms_ctl_master_t | busMaster | ) |

Reads the saved protection context (PC) for the referenced bus master.

Parameters

  busMaster | Bus master for which the saved PC value is being read

Returns
  Protection Context value

## ◆ Cy_Ms_Ctl_GetPcHandler()

cy_israddress Cy_Ms_Ctl_GetPcHandler | ( | uint32_t | pc | ) |

Reads the handler address for the given PC.

Parameters

  pc | Protection context for which the handler is being read

Returns
  Address of the protection context handler

## ◆ Cy_Ms_Ctl_ConfigBusMasterV1()

cy_en_ms_ctl_status_t Cy_Ms_Ctl_ConfigBusMasterV1 | ( | en_ms_ctl_master_t | busMaster,
|  | bool | privileged,
|  | bool | nonSecure,
|  | uint32_t | pcMask
| ) |  |

Configures the referenced bus master by setting the privilege, non-secure and protection context (PC) mask settings in APPCPUSS.

Parameters

  busMaster | Bus master being initialized
  privileged | privileged setting, 'false': user mode; 'true': privileged mode
  pcMask | pcMask
  nonSecure | Bus master security setting, 'false': secure; 'true': non-secure

Returns
  Requested operation status

## ◆ Cy_Ms_Ctl_ConfigMscAcgRespV1()

cy_en_ms_ctl_status_t Cy_Ms_Ctl_ConfigMscAcgRespV1 | ( | en_ms_ctl_master_sc_acg_v1_t | busMaster,
|  | cy_en_ms_ctl_cfg_gate_resp_t | gateResp,
|  | cy_en_ms_ctl_sec_resp_t | secResp
| ) |  |

Response configuration for ACG and MSC for the referenced bus master in APPCPUSS.

Parameters

  busMaster | Bus master for which response is being initialized
  gateResp | Response type when the ACG is blocking the incoming transfers:
  secResp | Bust master privileged setting

Returns
  Requested operation status

## ◆ Cy_Ms_Ctl_SetActivePCV1()

__STATIC_INLINE cy_en_ms_ctl_status_t Cy_Ms_Ctl_SetActivePCV1 | ( | en_ms_ctl_master_t | busMaster,
|  | uint32_t | pc
| ) |  |

Set active protection context (PCTX) for the referenced bus master in APPCPUSS.

Parameters

  busMaster | Bus master being initialized
  p_ctx | Protection Context value

Returns
  Requested operation status

## ◆ Cy_Ms_Ctl_GetActivePCV1()

__STATIC_INLINE uint32_t Cy_Ms_Ctl_GetActivePCV1 | ( | en_ms_ctl_master_t | busMaster | ) |

Reads the active protection context (PCTX) for the referenced bus master in APPCPUSS.

Parameters

  busMaster | Bus master for which the PC value is being read

Returns
  Protection Context value