/*
* GRUB -- GRand Unified Bootloader
* Copyright (C) 2005,2006,2007,2008,2009 Free Software Foundation, Inc.
*
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* GRUB is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GRUB. If not, see <http://www.gnu.org/licenses/>.
*/
#include <grub/video_fb.h>
GRUB_MOD_LICENSE ("GPLv3+");
/* Only 8-bit indexed color is supported for now. */
static int restore_needed;
static char *display;
static int have_setcolors = 0;
static struct
{
} framebuffer;
static grub_err_t
struct grub_video_palette_data *palette_data);
static void
{
/* TODO */
}
static void
find_display (void)
{
{
{
return 1;
}
return 0;
}
}
static grub_err_t
grub_video_ieee1275_init (void)
{
"stdout", &stdout_ihandle,
sizeof (stdout_ihandle), &actual)
&& actual == sizeof (stdout_ihandle))
have_setcolors = 1;
return grub_video_fb_init ();
}
static grub_err_t
grub_video_ieee1275_fini (void)
{
if (restore_needed)
{
restore_needed = 0;
}
return grub_video_fb_fini ();
}
static grub_err_t
struct grub_video_mode_info *out)
{
sizeof (tmp), 0))
sizeof (tmp), 0))
sizeof (tmp), 0))
return GRUB_ERR_NONE;
}
static grub_err_t
{
if (!display)
sizeof (current_width), 0))
sizeof (current_width), 0))
{
}
else
{
/* TODO. */
}
if (err)
{
return err;
}
sizeof (address), 0))
/* For some reason sparc64 uses 32-bit pointer too. */
if (err)
return err;
return err;
}
static grub_err_t
void **framebuf)
{
return GRUB_ERR_NONE;
}
static grub_err_t
struct grub_video_palette_data *palette_data)
{
if (err)
return err;
/* Set colors. */
if (have_setcolors)
{
unsigned col;
fb_palette_data[col].g,
fb_palette_data[col].b);
}
return GRUB_ERR_NONE;
}
{
.name = "IEEE1275 video driver",
.next = 0
};
{
find_display ();
if (display)
}
{
if (restore_needed)
{
restore_needed = 0;
}
if (display)
}