Console driver mod question:

From: Mike A. Harris (mharris@meteng.on.ca)
Date: Thu Feb 24 2000 - 13:15:39 EST


In char/vt.c, if I were to modify the call to vc_resize_all()
below....

        case VT_RESIZE:
        {
                struct vt_sizes *vtsizes = (struct vt_sizes *) arg;
                ushort ll,cc;
                if (!perm)
                        return -EPERM;
                i = verify_area(VERIFY_READ, (void *)vtsizes, sizeof(struct vt_sizes));
                if (i)
                        return i;
                get_user(ll, &vtsizes->v_rows);
                get_user(cc, &vtsizes->v_cols);
                return vc_resize_all(ll, cc);
        }

... to read "return vc_resize(ll, cc, console, console);" in
order to have only the current console resized instead of every
one of them, what would the repercussions possibly be? Should I
also modify the IOCTL below it (VT_RESIZEX)? And, would any
other major mod be needed in the kernel for it to work properly?

I've examined console.c, and vt.c, among many other files, and
did a fair amount of rgrep()ing on the source, and the only code
I find that accesses vc_resize() is vc_resize_all() implying that
the kernel contains no method of resizing a single console
exported to userland, however the framework is there in
vc_resize().

If my above code mod assumption works, then what would it
potentially cause problems with in userland?

Should I create a new ioctl()? VT_RESIZE_CUR?

Keep in mind, these modifications are for my use only. I am not
intending on them making the official kernel, so a semi-hack is
fine.

Any advice appreciated.

-- 
Mike A. Harris                                     Linux advocate     
Computer Consultant                                  GNU advocate  
Capslock Consulting                          Open Source advocate

Suspicious Anagram #4: Word: PRESIDENT CLINTON OF THE USA Anagram: TO COPULATE HE FINDS INTERNS

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Tue Feb 29 2000 - 21:00:10 EST