Exemplo n.º 1
0
/**
 * Called after processing of default and command-line-specified
 * chardevs to deliver CHR_EVENT_OPENED events to any FEs attached
 * to a mux chardev. This is done here to ensure that
 * output/prompts/banners are only displayed for the FE that has
 * focus when initial command-line processing/machine init is
 * completed.
 *
 * After this point, any new FE attached to any new or existing
 * mux will receive CHR_EVENT_OPENED notifications for the BE
 * immediately.
 */
static int open_muxes(Chardev *chr)
{
    /* send OPENED to all already-attached FEs */
    mux_chr_send_all_event(chr, CHR_EVENT_OPENED);
    /*
     * mark mux as OPENED so any new FEs will immediately receive
     * OPENED event
     */
    qemu_chr_be_event(chr, CHR_EVENT_OPENED);

    return 0;
}
Exemplo n.º 2
0
Arquivo: char.c Projeto: mdroth/qemu
/**
 * Called after processing of default and command-line-specified
 * chardevs to deliver CHR_EVENT_OPENED events to any FEs attached
 * to a mux chardev. This is done here to ensure that
 * output/prompts/banners are only displayed for the FE that has
 * focus when initial command-line processing/machine init is
 * completed.
 *
 * After this point, any new FE attached to any new or existing
 * mux will receive CHR_EVENT_OPENED notifications for the BE
 * immediately.
 */
static int open_muxes(Object *child, void *opaque)
{
    if (CHARDEV_IS_MUX(child)) {
        /* send OPENED to all already-attached FEs */
        mux_chr_send_all_event(CHARDEV(child), CHR_EVENT_OPENED);
        /* mark mux as OPENED so any new FEs will immediately receive
         * OPENED event
         */
        qemu_chr_be_event(CHARDEV(child), CHR_EVENT_OPENED);
    }

    return 0;
}
Exemplo n.º 3
0
static void mux_chr_event(void *opaque, int event)
{
    mux_chr_send_all_event(CHARDEV(opaque), event);
}