1 /* SPDX-License-Identifier: GPL-2.0 */
3 * Copyright (C) 2020 Marvell International Ltd.
5 * Fixes and workaround for Octeon chip errata. This file
6 * contains functions called by cvmx-helper to workaround known
7 * chip errata. For the most part, code doesn't need to call
8 * these functions directly.
11 #ifndef __CVMX_HELPER_ERRATA_H__
12 #define __CVMX_HELPER_ERRATA_H__
18 * Function to adjust internal IPD pointer alignments
20 * @return 0 on success
23 int __cvmx_helper_errata_fix_ipd_ptr_alignment(void);
26 * This function needs to be called on all Octeon chips with
29 * The Size field is 8 too large in WQE and next pointers
31 * The Size field generated by IPD is 8 larger than it should
32 * be. The Size field is <55:40> of both:
33 * - WORD3 in the work queue entry, and
34 * - the next buffer pointer (which precedes the packet data
37 * @param work Work queue entry to fix
38 * @return Zero on success. Negative on failure
40 int cvmx_helper_fix_ipd_packet_chain(cvmx_wqe_t *work);
43 * Due to errata G-720, the 2nd order CDR circuit on CN52XX pass
44 * 1 doesn't work properly. The following code disables 2nd order
45 * CDR for the specified QLM.
47 * @param qlm QLM to disable 2nd order CDR for.
49 void __cvmx_helper_errata_qlm_disable_2nd_order_cdr(int qlm);