Deleted Added
full compact
scterm-teken.c (199250) scterm-teken.c (223575)
1/*-
2 * Copyright (c) 1999 Kazutaka YOKOTA <yokota@zodiac.mech.utsunomiya-u.ac.jp>
3 * All rights reserved.
4 *
5 * Copyright (c) 2008-2009 Ed Schouten <ed@FreeBSD.org>
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 14 unchanged lines hidden (view full) ---

23 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
27 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 */
29
30#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 1999 Kazutaka YOKOTA <yokota@zodiac.mech.utsunomiya-u.ac.jp>
3 * All rights reserved.
4 *
5 * Copyright (c) 2008-2009 Ed Schouten <ed@FreeBSD.org>
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 14 unchanged lines hidden (view full) ---

23 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
27 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 */
29
30#include <sys/cdefs.h>
31__FBSDID("$FreeBSD: head/sys/dev/syscons/scterm-teken.c 199250 2009-11-13 11:28:54Z ed $");
31__FBSDID("$FreeBSD: head/sys/dev/syscons/scterm-teken.c 223575 2011-06-26 18:26:20Z ed $");
32
33#include "opt_syscons.h"
34#include "opt_teken.h"
35
36#include <sys/param.h>
37#include <sys/systm.h>
38#include <sys/kernel.h>
39#include <sys/module.h>

--- 598 unchanged lines hidden (view full) ---

638 src = r->tr_begin.tp_row * scp->xsize +
639 r->tr_begin.tp_col;
640 end = r->tr_end.tp_row * scp->xsize +
641 r->tr_end.tp_col;
642 dst = p->tp_row * scp->xsize + p->tp_col;
643
644 while (src < end) {
645 sc_vtb_move(&scp->vtb, src, dst, width);
32
33#include "opt_syscons.h"
34#include "opt_teken.h"
35
36#include <sys/param.h>
37#include <sys/systm.h>
38#include <sys/kernel.h>
39#include <sys/module.h>

--- 598 unchanged lines hidden (view full) ---

638 src = r->tr_begin.tp_row * scp->xsize +
639 r->tr_begin.tp_col;
640 end = r->tr_end.tp_row * scp->xsize +
641 r->tr_end.tp_col;
642 dst = p->tp_row * scp->xsize + p->tp_col;
643
644 while (src < end) {
645 sc_vtb_move(&scp->vtb, src, dst, width);
646
646
647 src += scp->xsize;
648 dst += scp->xsize;
649 }
650 } else {
651 /* Copy from bottom to top. */
652 src = (r->tr_end.tp_row - 1) * scp->xsize +
653 r->tr_begin.tp_col;
654 end = r->tr_begin.tp_row * scp->xsize +
655 r->tr_begin.tp_col;
656 dst = (p->tp_row + r->tr_end.tp_row -
657 r->tr_begin.tp_row - 1) * scp->xsize + p->tp_col;
658
659 while (src >= end) {
660 sc_vtb_move(&scp->vtb, src, dst, width);
647 src += scp->xsize;
648 dst += scp->xsize;
649 }
650 } else {
651 /* Copy from bottom to top. */
652 src = (r->tr_end.tp_row - 1) * scp->xsize +
653 r->tr_begin.tp_col;
654 end = r->tr_begin.tp_row * scp->xsize +
655 r->tr_begin.tp_col;
656 dst = (p->tp_row + r->tr_end.tp_row -
657 r->tr_begin.tp_row - 1) * scp->xsize + p->tp_col;
658
659 while (src >= end) {
660 sc_vtb_move(&scp->vtb, src, dst, width);
661
661
662 src -= scp->xsize;
663 dst -= scp->xsize;
664 }
665 }
666 }
667
668 /* Mark begin and end positions to be refreshed. */
669 mark_for_update(scp,

--- 43 unchanged lines hidden ---
662 src -= scp->xsize;
663 dst -= scp->xsize;
664 }
665 }
666 }
667
668 /* Mark begin and end positions to be refreshed. */
669 mark_for_update(scp,

--- 43 unchanged lines hidden ---