#!/usr/sbin/sh # # Copyright (c) 1994, 2013, Oracle and/or its affiliates. All rights reserved. # # Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T. # All rights reserved. # # This file loads keyboard mappings and initializes keyboard defaults . /lib/svc/share/smf_include.sh smf_assert_globalzone init_keyboard () { if [ -h /dev/kbd ]; then # Initialize the keyboard defaults /usr/bin/kbd -i >/dev/null 2>&1 # Load the keymap for the attached keyboard. /usr/bin/loadkeys fi } case "$1" in 'start') # # Systems with no hardware keyboard ID may provide an eeprom value, # or the value can be supplied in svc:/system/keymap:default. A value # supplied in svc:/system/keymap:default will override the value # supplied in eeprom. # /usr/lib/set_keyboard_layout init_keyboard ;; 'refresh') init_keyboard ;; 'unconfigure') /usr/sbin/svccfg -s $SMF_FMRI delcust keymap /usr/sbin/svcadm refresh $SMF_FMRI ;; *) echo "Usage: $0 {start | refresh | unconfigure}" ;; esac exit $SMF_EXIT_OK