18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */ 28c2ecf20Sopenharmony_ci/* 38c2ecf20Sopenharmony_ci * This file describes the structure passed from the BootX application 48c2ecf20Sopenharmony_ci * (for MacOS) when it is used to boot Linux. 58c2ecf20Sopenharmony_ci * 68c2ecf20Sopenharmony_ci * Written by Benjamin Herrenschmidt. 78c2ecf20Sopenharmony_ci */ 88c2ecf20Sopenharmony_ci 98c2ecf20Sopenharmony_ci#ifndef __ASM_BOOTX_H__ 108c2ecf20Sopenharmony_ci#define __ASM_BOOTX_H__ 118c2ecf20Sopenharmony_ci 128c2ecf20Sopenharmony_ci#include <uapi/asm/bootx.h> 138c2ecf20Sopenharmony_ci 148c2ecf20Sopenharmony_ci/* (*) The format of the colormap is 256 * 3 * 2 bytes. Each color index 158c2ecf20Sopenharmony_ci * is represented by 3 short words containing a 16 bits (unsigned) color 168c2ecf20Sopenharmony_ci * component. Later versions may contain the gamma table for direct-color 178c2ecf20Sopenharmony_ci * devices here. 188c2ecf20Sopenharmony_ci */ 198c2ecf20Sopenharmony_ci#define BOOTX_COLORTABLE_SIZE (256UL*3UL*2UL) 208c2ecf20Sopenharmony_ci 218c2ecf20Sopenharmony_ci/* BootX passes the device-tree using a format that comes from earlier 228c2ecf20Sopenharmony_ci * ppc32 kernels. This used to match what is in prom.h, but not anymore 238c2ecf20Sopenharmony_ci * so we now define it here 248c2ecf20Sopenharmony_ci */ 258c2ecf20Sopenharmony_cistruct bootx_dt_prop { 268c2ecf20Sopenharmony_ci u32 name; 278c2ecf20Sopenharmony_ci int length; 288c2ecf20Sopenharmony_ci u32 value; 298c2ecf20Sopenharmony_ci u32 next; 308c2ecf20Sopenharmony_ci}; 318c2ecf20Sopenharmony_ci 328c2ecf20Sopenharmony_cistruct bootx_dt_node { 338c2ecf20Sopenharmony_ci u32 unused0; 348c2ecf20Sopenharmony_ci u32 unused1; 358c2ecf20Sopenharmony_ci u32 phandle; /* not really available */ 368c2ecf20Sopenharmony_ci u32 unused2; 378c2ecf20Sopenharmony_ci u32 unused3; 388c2ecf20Sopenharmony_ci u32 unused4; 398c2ecf20Sopenharmony_ci u32 unused5; 408c2ecf20Sopenharmony_ci u32 full_name; 418c2ecf20Sopenharmony_ci u32 properties; 428c2ecf20Sopenharmony_ci u32 parent; 438c2ecf20Sopenharmony_ci u32 child; 448c2ecf20Sopenharmony_ci u32 sibling; 458c2ecf20Sopenharmony_ci u32 next; 468c2ecf20Sopenharmony_ci u32 allnext; 478c2ecf20Sopenharmony_ci}; 488c2ecf20Sopenharmony_ci 498c2ecf20Sopenharmony_ciextern void bootx_init(unsigned long r4, unsigned long phys); 508c2ecf20Sopenharmony_ci 518c2ecf20Sopenharmony_ci#endif 52