/*  *********************************************************************
    *  ASTRIS - Remote JTAG probe
    *
    *  KIS API             File: astris_kis_error.h
    *
    *  KIS Error Handling API Decleration
    *
    *
    *********************************************************************
    *
    *  Copyright (C) 2016-2019  Apple, Inc. All rights reserved.
    *
    *  This document is the property of Apple Inc.
    *  It is considered confidential and proprietary.
    *
    *  This document may not be reproduced or transmitted in any form,
    *  in whole or in part, without the express written permission of
    *  Apple Inc.
    ********************************************************************* */

#ifndef _ASTRIS_KIS_ERROR_H
#define _ASTRIS_KIS_ERROR_H

#include "astris_api.h"
#include "astris_internal.h"
#include "astris_except.h"

// Forward declare of struct
struct dapcmd_s;

int astris_kis_handle_result_memap(AXconn_t *conn, int xfer_result, uint8_t select, struct dapcmd_s *dapcmd);
int astris_kis_handle_result(AXconn_t *conn, AXportal_t *portal, struct dapcmd_s *dapcmd, bool ignore_error = true);
int astris_kis_clear_status_registers(AXconn_t *conn, AXportal_t *portal);

#endif /* _ASTRIS_KIS_ERROR_H */
