/* Wait for all the BDs marked sent */ while(!cpm_uart_tx_empty(port)) schedule_timeout(2); if(pinfo->wait_closing) cpm_uart_wait_until_send(pinfo);  
static void cpm_uart_shutdown(struct uart_port *port){	struct uart_cpm_port *pinfo = (struct uart_cpm_port *)port;	int line = pinfo - cpm_uart_ports;	pr_debug("CPM uart[%d]:shutdown\n", port->line);	/* free interrupt handler */	free_irq(port->irq, port);	/* If the port is not the console, disable Rx and Tx. */	if (!(pinfo->flags & FLAG_CONSOLE)) {		/* Stop uarts */		if (IS_SMC(pinfo)) {			volatile smc_t *smcp = pinfo->smcp;			smcp->smc_smcmr &= ~(SMCMR_REN | SMCMR_TEN);			smcp->smc_smcm &= ~(SMCM_RX | SMCM_TX);		} else {			volatile scc_t *sccp = pinfo->sccp;			sccp->scc_gsmrl &= ~(SCC_GSMRL_ENR | SCC_GSMRL_ENT);			sccp->scc_sccm &= ~(UART_SCCM_TX | UART_SCCM_RX);		}		/* Shut them really down and reinit buffer descriptors */		cpm_line_cr_cmd(line, CPM_CR_STOP_TX);		cpm_uart_initbd(pinfo);	}}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/311c46273f0e8b140d4cc68e13128cbc22114807/cpm_uart_core.c/clean/drivers/serial/cpm_uart/cpm_uart_core.c