aiengine: xaietile_pl.c File Reference

| aiengine Xilinx SDK Drivers API Documentation

- Overview
- Data Structures
- APIs
- File List

xaietile_pl.c File Reference

## Overview

This file contains APIs for PL module.

    MODIFICATION HISTORY:

    Ver   Who       Date        Changes

    1.0  Jubaer  01/29/2019  Initial creation
    1.1  Jubaer  03/07/2019  Add Shim Reset Enable
    1.2  Hyun    06/27/2019  Add XAieTile_PlReadTimer()

u32 | XAieTile_PlIntcL1Mask (XAieGbl_Tile *TileInstPtr, u8 SwitchAB)
| This API is used to read the current value of the 1st level interrupt controller mask. More...
void | XAieTile_PlIntcL1Enable (XAieGbl_Tile *TileInstPtr, u32 Mask, u8 SwitchAB)
| This API is used to enable individual interrupts by setting bits in the mask value. More...
void | XAieTile_PlIntcL1Disable (XAieGbl_Tile *TileInstPtr, u32 Mask, u8 SwitchAB)
| This API is used to disable individual interrupts by clearing bits in the mask value. More...
u32 | XAieTile_PlIntcL1StatusGet (XAieGbl_Tile *TileInstPtr, u8 SwitchAB)
| This API is used to read the 1st level status register of interrupt controller. More...
void | XAieTile_PlIntcL1StatusClr (XAieGbl_Tile *TileInstPtr, u32 Status, u8 SwitchAB)
| This API is used to clear status register of 1st level interrupt. More...
u32 | XAieTile_PlIntcL1IrqNoGet (XAieGbl_Tile *TileInstPtr, u8 SwitchAB)
| This API is used to read which broadcast event signal the interrupt shall be driven to. More...
void | XAieTile_PlIntcL1IrqNoSet (XAieGbl_Tile *TileInstPtr, u32 irqNum, u8 SwitchAB)
| This API is used to set which broadcast event signal the interrupt shall be driven to. More...
u32 | XAieTile_PlIntcL1BlockNorthVal (XAieGbl_Tile *TileInstPtr, u8 SwitchAB)
| This API is used to read the interrupt controller 1st level north block value. More...
void | XAieTile_PlIntcL1BlockNorthSet (XAieGbl_Tile *TileInstPtr, u32 Mask, u8 SwitchAB)
| This API is used to set the north block of 1st level interrupt controller. More...
void | XAieTile_PlIntcL1BlockNorthClr (XAieGbl_Tile *TileInstPtr, u32 Mask, u8 SwitchAB)
| This API is used to clear the north block of 1st level interrupt controller. More...
u8 | XAieTile_PlShimResetEnable (XAieGbl_Tile *TileInstPtr, u8 Reset)
| This API enable / disable the shim reset to given time. More...
u64 | XAieTile_PlReadTimer (XAieGbl_Tile *TileInstPtr)
| This API returns the current value of the PL module 64-bit timer. More...

## Function Documentation

void XAieTile_PlIntcL1BlockNorthClr | ( | XAieGbl_Tile * | TileInstPtr,
|  | u32 | Mask,
|  | u8 | SwitchAB
| ) |  |

This API is used to clear the north block of 1st level interrupt controller.

Parameters

  TileInstPtr | - Pointer to the Tile instance.
  Mask | - Mask with bits to clear.
  SwitchAB | - Flag to indicate if it's the A or B block.

Returns
  None.

Note
  None.

References XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

void XAieTile_PlIntcL1BlockNorthSet | ( | XAieGbl_Tile * | TileInstPtr,
|  | u32 | Mask,
|  | u8 | SwitchAB
| ) |  |

This API is used to set the north block of 1st level interrupt controller.

Parameters

  TileInstPtr | - Pointer to the Tile instance.
  Mask | - Mask with bits to set.
  SwitchAB | - Flag to indicate if it's the A or B block.

Returns
  None.

Note
  None.

References XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

u32 XAieTile_PlIntcL1BlockNorthVal | ( | XAieGbl_Tile * | TileInstPtr,
|  | u8 | SwitchAB
| ) |  |

This API is used to read the interrupt controller 1st level north block value.

Parameters

  TileInstPtr | - Pointer to the Tile instance.
  SwitchAB | - Flag to indicate if it's the A or B block.

Returns
  Return current value of block.

Note
  None.

References XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

void XAieTile_PlIntcL1Disable | ( | XAieGbl_Tile * | TileInstPtr,
|  | u32 | Mask,
|  | u8 | SwitchAB
| ) |  |

This API is used to disable individual interrupts by clearing bits in the mask value.

Parameters

  TileInstPtr | - Pointer to the Tile instance.
  Mask | - Mask with bits to clear
  SwitchAB | - Flag to indicate if it's the A or B block.

Returns
  None.

Note
  None.

References XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

void XAieTile_PlIntcL1Enable | ( | XAieGbl_Tile * | TileInstPtr,
|  | u32 | Mask,
|  | u8 | SwitchAB
| ) |  |

This API is used to enable individual interrupts by setting bits in the mask value.

Parameters

  TileInstPtr | - Pointer to the Tile instance.
  Mask | - Mask with bits to set
  SwitchAB | - Flag to indicate if it's the A or B block.

Returns
  None.

Note
  None.

References XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

u32 XAieTile_PlIntcL1IrqNoGet | ( | XAieGbl_Tile * | TileInstPtr,
|  | u8 | SwitchAB
| ) |  |

This API is used to read which broadcast event signal the interrupt shall be driven to.

Parameters

  TileInstPtr | - Pointer to the Tile instance.
  SwitchAB | - Flag to indicate if it's the A or B block.

Returns
  1st level broadcast number (4 bits)

Note
  None.

References XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

void XAieTile_PlIntcL1IrqNoSet | ( | XAieGbl_Tile * | TileInstPtr,
|  | u32 | irqNum,
|  | u8 | SwitchAB
| ) |  |

This API is used to set which broadcast event signal the interrupt shall be driven to.

Parameters

  TileInstPtr | - Pointer to the Tile instance.
  irqNum | - Mask with bits to set
  SwitchAB | - Flag to indicate if it's the A or B block.

Returns
  None.

Note
  None.

References XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

u32 XAieTile_PlIntcL1Mask | ( | XAieGbl_Tile * | TileInstPtr,
|  | u8 | SwitchAB
| ) |  |

This API is used to read the current value of the 1st level interrupt controller mask.

Parameters

  TileInstPtr | - Pointer to the Tile instance.
  SwitchAB | - Flag to indicate if it's the A or B block. Should be one of XAIETILE_EVENT_BLOCK_SWITCHA or XAIETILE_EVENT_BLOCK_SWITCHB.

Returns
  Current value of the mask

Note
  None.

References XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

void XAieTile_PlIntcL1StatusClr | ( | XAieGbl_Tile * | TileInstPtr,
|  | u32 | Status,
|  | u8 | SwitchAB
| ) |  |

This API is used to clear status register of 1st level interrupt.

Parameters

  TileInstPtr | - Pointer to the Tile instance.
  Status | - 32-bit register to clear status register.
  SwitchAB | - Flag to indicate if it's the A or B block.

Returns
  None.

Note
  None.

References XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

u32 XAieTile_PlIntcL1StatusGet | ( | XAieGbl_Tile * | TileInstPtr,
|  | u8 | SwitchAB
| ) |  |

This API is used to read the 1st level status register of interrupt controller.

Parameters

  TileInstPtr | - Pointer to the Tile instance.
  SwitchAB | - Flag to indicate if it's the A or B block.

Returns
  Status - unsigned 32 bits indicating the Status of the 1st level interrupt controller.

Note
  None.

References XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

u64 XAieTile_PlReadTimer | ( | XAieGbl_Tile * | TileInstPtr | ) |

This API returns the current value of the PL module 64-bit timer.

Parameters

  TileInstPtr | - Pointer to the Tile instance.

Returns
  64-bit timer value.

Note
  None.

References XAieGbl_RegTimer::HighOff, XAieGbl_RegTimer::LowOff, XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.

u8 XAieTile_PlShimResetEnable | ( | XAieGbl_Tile * | TileInstPtr,
|  | u8 | Reset
| ) |  |

This API enable / disable the shim reset to given time.

Parameters

  TileInstPtr | - Pointer to the Shim tile instance.
  Reset | - 1 for enable. 0 for disable.

Returns
  XAIE_SUCCESS on success

Note
  None.

References XAieGbl_RegShimReset::RegOff, XAieGbl_Tile::TileAddr, and XAieGbl_Tile::TileType.