aml8726_sdxc-m8.c (297127) | aml8726_sdxc-m8.c (297793) |
---|---|
1/*- 2 * Copyright 2015 John Wehle <john@feith.com> 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 15 unchanged lines hidden (view full) --- 24 * SUCH DAMAGE. 25 */ 26 27/* 28 * Amlogic aml8726-m8 (and later) SDXC host controller driver. 29 */ 30 31#include <sys/cdefs.h> | 1/*- 2 * Copyright 2015 John Wehle <john@feith.com> 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 15 unchanged lines hidden (view full) --- 24 * SUCH DAMAGE. 25 */ 26 27/* 28 * Amlogic aml8726-m8 (and later) SDXC host controller driver. 29 */ 30 31#include <sys/cdefs.h> |
32__FBSDID("$FreeBSD: head/sys/arm/amlogic/aml8726/aml8726_sdxc-m8.c 297127 2016-03-21 00:52:24Z ian $"); | 32__FBSDID("$FreeBSD: head/sys/arm/amlogic/aml8726/aml8726_sdxc-m8.c 297793 2016-04-10 23:07:00Z pfg $"); |
33 34#include <sys/param.h> 35#include <sys/systm.h> 36#include <sys/conf.h> 37#include <sys/bus.h> 38#include <sys/kernel.h> 39#include <sys/module.h> 40#include <sys/lock.h> --- 575 unchanged lines hidden (view full) --- 616 617 aml8726_sdxc_disengage_dma(sc); 618 619 if ((sndr & AML_SDXC_SEND_CMD_HAS_RESP) != 0) { 620 start = 0; 621 stop = 1; 622 if ((sndr & AML_SDXC_SEND_RESP_136) != 0) { 623 start = 1; | 33 34#include <sys/param.h> 35#include <sys/systm.h> 36#include <sys/conf.h> 37#include <sys/bus.h> 38#include <sys/kernel.h> 39#include <sys/module.h> 40#include <sys/lock.h> --- 575 unchanged lines hidden (view full) --- 616 617 aml8726_sdxc_disengage_dma(sc); 618 619 if ((sndr & AML_SDXC_SEND_CMD_HAS_RESP) != 0) { 620 start = 0; 621 stop = 1; 622 if ((sndr & AML_SDXC_SEND_RESP_136) != 0) { 623 start = 1; |
624 stop = start + 4;; | 624 stop = start + 4; |
625 } 626 for (i = start; i < stop; i++) { 627 pdmar = CSR_READ_4(sc, AML_SDXC_PDMA_REG); 628 pdmar &= ~(AML_SDXC_PDMA_DMA_EN | 629 AML_SDXC_PDMA_RESP_INDEX_MASK); 630 pdmar |= i << AML_SDXC_PDMA_RESP_INDEX_SHIFT; 631 CSR_WRITE_4(sc, AML_SDXC_PDMA_REG, pdmar); 632 sc->cmd->resp[(stop - 1) - i] = CSR_READ_4(sc, --- 749 unchanged lines hidden --- | 625 } 626 for (i = start; i < stop; i++) { 627 pdmar = CSR_READ_4(sc, AML_SDXC_PDMA_REG); 628 pdmar &= ~(AML_SDXC_PDMA_DMA_EN | 629 AML_SDXC_PDMA_RESP_INDEX_MASK); 630 pdmar |= i << AML_SDXC_PDMA_RESP_INDEX_SHIFT; 631 CSR_WRITE_4(sc, AML_SDXC_PDMA_REG, pdmar); 632 sc->cmd->resp[(stop - 1) - i] = CSR_READ_4(sc, --- 749 unchanged lines hidden --- |