linux-next.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Rothwell <sfr@canb.auug.org.au>
To: Greg KH <greg@kroah.com>
Cc: linux-next@vger.kernel.org, linux-kernel@vger.kernel.org,
	Jiri Slaby <jslaby@suse.cz>,
	Samuel Iglesias Gonsalvez <siglesias@igalia.com>
Subject: linux-next: manual merge of the staging tree with the tty tree
Date: Mon, 17 Sep 2012 17:37:06 +1000	[thread overview]
Message-ID: <20120917173706.44575edebd95adaebe557b67@canb.auug.org.au> (raw)

[-- Attachment #1: Type: text/plain, Size: 3416 bytes --]

Hi Greg,

Today's linux-next merge of the staging tree got a conflict in
drivers/staging/ipack/devices/ipoctal.c between commit 734cc1783816
("TTY: use tty_port_register_device") from the tty tree and commit
d04600679ba0 ("Staging: ipack/devices/ipoctal: simplify ipoctal_write_tty
()") from the staging tree.

I fixed it up (see below) and can carry the fix as necessary (no action
is required).

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

diff --cc drivers/staging/ipack/devices/ipoctal.c
index a68d981,2cdbf28..0000000
--- a/drivers/staging/ipack/devices/ipoctal.c
+++ b/drivers/staging/ipack/devices/ipoctal.c
@@@ -490,19 -429,26 +429,26 @@@ static int ipoctal_inst_slot(struct ipo
  	ipoctal->tty_drv = tty;
  
  	for (i = 0; i < NR_CHANNELS; i++) {
- 		tty_port_init(&ipoctal->tty_port[i]);
- 		tty_port_alloc_xmit_buf(&ipoctal->tty_port[i]);
- 		ipoctal->tty_port[i].ops = &ipoctal_tty_port_ops;
- 
- 		ipoctal_reset_stats(&ipoctal->chan_stats[i]);
- 		ipoctal->nb_bytes[i] = 0;
- 		init_waitqueue_head(&ipoctal->queue[i]);
- 
- 		spin_lock_init(&ipoctal->lock[i]);
- 		ipoctal->pointer_read[i] = 0;
- 		ipoctal->pointer_write[i] = 0;
- 		ipoctal->nb_bytes[i] = 0;
- 		tty_port_register_device(&ipoctal->tty_port[i], tty, i, NULL);
+ 		struct device *tty_dev;
+ 
+ 		channel = &ipoctal->channel[i];
+ 		tty_port_init(&channel->tty_port);
+ 		tty_port_alloc_xmit_buf(&channel->tty_port);
+ 		channel->tty_port.ops = &ipoctal_tty_port_ops;
+ 
+ 		ipoctal_reset_stats(&channel->stats);
+ 		channel->nb_bytes = 0;
+ 		init_waitqueue_head(&channel->queue);
+ 
+ 		spin_lock_init(&channel->lock);
+ 		channel->pointer_read = 0;
+ 		channel->pointer_write = 0;
 -		tty_dev = tty_register_device(tty, i, NULL);
++		tty_dev = tty_port_register_device(&channel->tty_port, tty, i, NULL);
+ 		if (IS_ERR(tty_dev)) {
+ 			dev_err(&ipoctal->dev->dev, "Failed to register tty device.\n");
+ 			continue;
+ 		}
+ 		dev_set_drvdata(tty_dev, channel);
  
  		/*
  		 * Enable again the RX. TX will be enabled when
@@@ -613,23 -540,17 +540,17 @@@ static void ipoctal_set_termios(struct 
  	unsigned char mr1 = 0;
  	unsigned char mr2 = 0;
  	unsigned char csr = 0;
- 	unsigned int channel = tty->index;
- 	struct ipoctal *ipoctal = tty->driver_data;
+ 	struct ipoctal_channel *channel = tty->driver_data;
  	speed_t baud;
  
 -	cflag = tty->termios->c_cflag;
 +	cflag = tty->termios.c_cflag;
  
  	/* Disable and reset everything before change the setup */
- 	ipoctal_write_io_reg(ipoctal, &ipoctal->chan_regs[channel].u.w.cr,
- 			     CR_DISABLE_RX | CR_DISABLE_TX);
- 	ipoctal_write_cr_cmd(ipoctal, &ipoctal->chan_regs[channel].u.w.cr,
- 			     CR_CMD_RESET_RX);
- 	ipoctal_write_cr_cmd(ipoctal, &ipoctal->chan_regs[channel].u.w.cr,
- 			     CR_CMD_RESET_TX);
- 	ipoctal_write_cr_cmd(ipoctal, &ipoctal->chan_regs[channel].u.w.cr,
- 			     CR_CMD_RESET_ERR_STATUS);
- 	ipoctal_write_cr_cmd(ipoctal, &ipoctal->chan_regs[channel].u.w.cr,
- 			     CR_CMD_RESET_MR);
+ 	iowrite8(CR_DISABLE_RX | CR_DISABLE_TX, &channel->regs->w.cr);
+ 	iowrite8(CR_CMD_RESET_RX, &channel->regs->w.cr);
+ 	iowrite8(CR_CMD_RESET_TX, &channel->regs->w.cr);
+ 	iowrite8(CR_CMD_RESET_ERR_STATUS, &channel->regs->w.cr);
+ 	iowrite8(CR_CMD_RESET_MR, &channel->regs->w.cr);
  
  	/* Set Bits per chars */
  	switch (cflag & CSIZE) {

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

             reply	other threads:[~2012-09-17  7:37 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-17  7:37 Stephen Rothwell [this message]
2012-09-17 11:20 ` linux-next: manual merge of the staging tree with the tty tree Greg KH
  -- strict thread matches above, loose matches on Subject: below --
2022-10-04  6:33 Stephen Rothwell
2022-10-04  8:26 ` Greg KH
2017-06-05  4:57 Stephen Rothwell
2017-06-05  6:50 ` Greg KH
2016-02-01  3:51 Stephen Rothwell
2016-02-01  4:01 ` Greg KH
2012-11-29  4:47 Stephen Rothwell
2012-11-29  5:17 ` Greg KH
2012-11-28  5:14 Stephen Rothwell
2012-11-28 16:47 ` Greg KH
2012-09-13  6:14 Stephen Rothwell
2012-09-13  6:59 ` Samuel Iglesias Gonsálvez
2012-09-13  7:36   ` Stephen Rothwell
2012-05-07  5:58 Stephen Rothwell
2012-05-07 14:48 ` Greg KH

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20120917173706.44575edebd95adaebe557b67@canb.auug.org.au \
    --to=sfr@canb.auug.org.au \
    --cc=greg@kroah.com \
    --cc=jslaby@suse.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=siglesias@igalia.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).