mirror of
https://github.com/SCST-project/scst.git
synced 2026-05-18 03:01:26 +00:00
Avoid that the checkpatch.pl script as included in Linux kernel 3.1
complains about min((int)(a), (int)(b)) that should be changed into min_t(int, (a), (b)) (merge r3944 from trunk). git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/2.2.0.x@4008 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
@@ -1464,7 +1464,7 @@ static int dev_user_process_reply_exec(struct scst_user_cmd *ucmd,
|
||||
if (res != 0)
|
||||
goto out_compl;
|
||||
|
||||
sense_len = min((int)cmd->sense_buflen, (int)ereply->sense_len);
|
||||
sense_len = min_t(int, cmd->sense_buflen, ereply->sense_len);
|
||||
|
||||
rc = copy_from_user(cmd->sense,
|
||||
(void __user *)(unsigned long)ereply->psense_buffer,
|
||||
|
||||
@@ -6316,7 +6316,7 @@ static void __scst_check_set_UA(struct scst_tgt_dev *tgt_dev,
|
||||
{
|
||||
int skip_UA = 0;
|
||||
struct scst_tgt_dev_UA *UA_entry_tmp;
|
||||
int len = min((int)sizeof(UA_entry_tmp->UA_sense_buffer), sense_len);
|
||||
int len = min_t(int, sizeof(UA_entry_tmp->UA_sense_buffer), sense_len);
|
||||
|
||||
TRACE_ENTRY();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user