1af3dc4a7SPedro F. Giffuni /*- 2*4d846d26SWarner Losh * SPDX-License-Identifier: BSD-2-Clause 3af3dc4a7SPedro F. Giffuni * 40050ea24SMichal Meloun * Copyright (c) 2020 Oskar Holmlund <oskar.holmlund@ohdata.se> 5e53470feSOleksandr Tymoshenko * 6e53470feSOleksandr Tymoshenko * Redistribution and use in source and binary forms, with or without 7e53470feSOleksandr Tymoshenko * modification, are permitted provided that the following conditions 8e53470feSOleksandr Tymoshenko * are met: 9e53470feSOleksandr Tymoshenko * 1. Redistributions of source code must retain the above copyright 10e53470feSOleksandr Tymoshenko * notice, this list of conditions and the following disclaimer. 11e53470feSOleksandr Tymoshenko * 2. Redistributions in binary form must reproduce the above copyright 12e53470feSOleksandr Tymoshenko * notice, this list of conditions and the following disclaimer in the 13e53470feSOleksandr Tymoshenko * documentation and/or other materials provided with the distribution. 14e53470feSOleksandr Tymoshenko * 150050ea24SMichal Meloun * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 16e53470feSOleksandr Tymoshenko * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 17e53470feSOleksandr Tymoshenko * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 180050ea24SMichal Meloun * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 190050ea24SMichal Meloun * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 200050ea24SMichal Meloun * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 210050ea24SMichal Meloun * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 220050ea24SMichal Meloun * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 230050ea24SMichal Meloun * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 240050ea24SMichal Meloun * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 250050ea24SMichal Meloun * SUCH DAMAGE. 26e53470feSOleksandr Tymoshenko */ 27e53470feSOleksandr Tymoshenko 280050ea24SMichal Meloun #ifndef __TI_PRCM_H__ 290050ea24SMichal Meloun #define __TI_PRCM_H__ 30e53470feSOleksandr Tymoshenko 310050ea24SMichal Meloun int ti_prcm_write_4(device_t dev, bus_addr_t addr, uint32_t val); 320050ea24SMichal Meloun int ti_prcm_read_4(device_t dev, bus_addr_t addr, uint32_t *val); 330050ea24SMichal Meloun int ti_prcm_modify_4(device_t dev, bus_addr_t addr, uint32_t clr, uint32_t set); 340050ea24SMichal Meloun void ti_prcm_device_lock(device_t dev); 350050ea24SMichal Meloun void ti_prcm_device_unlock(device_t dev); 36e53470feSOleksandr Tymoshenko 370050ea24SMichal Meloun #endif 38