Главная страница


ru.linux

 
 - RU.LINUX ---------------------------------------------------------------------
 From : Svyatoslav Abramenkov                2:464/8088.100 21 Jul 2004  11:25:38
 To : Vladislav Bondarenko
 Subject : ASP90+2.6.5
 -------------------------------------------------------------------------------- 
 
 
 At 20 Jul 04  09:09:06, Vladislav Bondarenko wrote to Svyatoslav Abramenkov:
 
  SA>>          Хм.
  SA>>  /*
  SA>>  *****************************************************
  SA>>  **    Tekram TRM_S1040 for DC395x driver, header file
  SA>>  *****************************************************
  SA>>  */
 
 [ ...skipped... ]
 
  SA>>  //-----------------------------------------------------
  SA>>  #if LINUX_VERSION_CODE < KERNEL_VERSION(1,3,50)
  SA>>          В своё время я взял это с дискетки, идущей в комплекте с
  SA>>  адаптером, и собрал модуль для ядра 2.2.13. Думаю, что копия этого
  SA>>  (причем собирающегося со всеми существующими на  сегодня версиями
  SA>>  ядра) наверняка лежит где-то на сайте Tekram, скорее всего, на самом
  SA>>  видном месте. Из последнего блока комментариев, кстати, видно, что оно
  SA>>  собирается с ядрами, как минимум, с версии 1.3.50.
  VB> Очень стpанно. Пpавда контpоллеp мне достался в пакетике без ничего, но я 
  VB> в упоp не вижу в 2.4.[20-22] ничего подобного dc395/315.
 
         В ванильных ядрах его нет, видимо, потому, что Линуса что-то не
 устраивало.
 
  VB> Hа сайт ходил, но путёвого ничего не нашёл.
  VB> Ладно, пpоехали, пусть каждый останется пpи своём мнении.
 
         Тогда сходи на
 ftp://ftp.tekram.com.cn/storage/SCSI/PCI/Dc-3x5/Driver&AP/
 
 и обнаружь там вот это, оно там в каждом архиве с "драйверами" для различных
 дистрибутивов находится:
 
 >===== Start cut [/tmp/1/dc395x_trm.h] =====<
 
 /*
 **********************************************************************
 **      File Name : dc395x_trm.h
 **                              
 **  TEKRAM DC395U/UW/F ,DC315/U
 **  PCI SCSI Bus Master Host AdapterDevice Driver
 **  (SCSI chip set used Tekram ASIC TRM-S1040)
 **                                               
 **********************************************************************
 */
 /* $Id: dc395x_trm.h,v 1.43 2002/06/21 09:57:38 garloff Exp $ */
 /*
 *****************************************************
 **    Tekram TRM_S1040 for DC395x driver, header file
 *****************************************************
 */
 #ifndef DC395x_trm_H
 #define DC395x_trm_H
 
 #include <linux/config.h>
 
 #define DC395x_BANNER "Tekram DC395U/UW/F DC315/U"
 #define DC395x_VERSION "1.41, 2002-06-21"
 
 /* Kernel version autodetection */
 #include <linux/version.h>
 #ifndef KERNEL_VERSION
 # define KERNEL_VERSION(V, P, S)        (((V) << 16) + ((P) << 8) + (S))
 #endif
 
 //-----------------------------------------------------
 #if LINUX_VERSION_CODE < KERNEL_VERSION(1,3,50)
        #define VERSION_ELF_1_2_13
 #elseif LINUX_VERSION_CODE < KERNEL_VERSION(1,3,95)
        #define VERSION_1_3_85
 #else
        #define VERSION_2_0_0
 #endif
 
 #if defined(__SMP__) && !defined(CONFIG_SMP)
 # define CONFIG_SMP
 #endif
 
 #define DC395x_MAX_CMD_QUEUE    32
 //#define DC395x_MAX_QTAGS      32
 #define DC395x_MAX_QTAGS        16
 #define DC395x_MAX_ADAPTER_NUM  4
 #define DC395x_MAX_SCSI_ID      16
 #define DC395x_MAX_CMD_PER_LUN  DC395x_MAX_QTAGS 
 #define DC395x_MAX_SG_TABLESIZE 64      /* HW limitation */
 #define DC395x_MAX_SG_LISTENTRY 64      /* Must be equal or lower to previous
 item 
 */
 #define DC395x_MAX_SRB_CNT      63
 //#define DC395x_MAX_CAN_QUEUE  7 * DC395x_MAX_QTAGS
 #define DC395x_MAX_CAN_QUEUE    DC395x_MAX_SRB_CNT
 #define DC395x_END_SCAN         2
 #define DC395x_SEL_TIMEOUT      153     /* 250 ms selection timeout (@ 40 MHz)
 */
 #define DC395x_MAX_RETRIES      3
 
 //#define SYNC_FIRST
 
 #if (LINUX_VERSION_CODE < KERNEL_VERSION (2,5,6) && !defined(FORCE_NEW_EH))
 /* Our new EH is not yet so well tested; only use it for 2.5 ... */
 # define OLD_EH
 #endif
 #if (LINUX_VERSION_CODE < KERNEL_VERSION (2,1,70)) || defined(OLD_EH)
 # define EH_FUNC        abort:          DC395x_abort,           \
 reset:          DC395x_reset,
 # define NORM_REC_LVL 1
 #else
 # define USE_NEW_EH
 # define NORM_REC_LVL 0
 # if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,14)
 #  define EH_FUNC       use_new_eh_code: 1,                     \
                         eh_abort_handler: DC395x_eh_abort,      \
                         eh_bus_reset_handler: DC395x_eh_bus_reset,
 # else
 #  define EH_FUNC       eh_abort_handler: DC395x_eh_abort,      \
                         eh_bus_reset_handler: DC395x_eh_bus_reset,
 # endif 
 #endif
 
 #if defined(HOSTS_C) || defined(MODULE) || LINUX_VERSION_CODE > KERNEL_VERSION
 (2,3,99)
 
 # include <scsi/scsicam.h>
 
 extern  int DC395x_detect(Scsi_Host_Template *psht);
 extern  int DC395x_queue_command(Scsi_Cmnd *cmd, void (*done)(Scsi_Cmnd *));
 # ifdef USE_NEW_EH
 extern int DC395x_eh_abort(Scsi_Cmnd * SCpnt);
 extern int DC395x_eh_bus_reset(Scsi_Cmnd * SCpnt);
 # else
 extern  int DC395x_abort(Scsi_Cmnd *cmd);
 extern  int DC395x_reset(Scsi_Cmnd *cmd ,unsigned int resetFlags);
 # endif
 extern  int DC395x_bios_param(Disk *disk, kdev_t devno, int geom[]);
 //--------------
 # ifdef  MODULE
 static  int DC395x_release(struct Scsi_Host *);
 # else
 #  define DC395x_release NULL
 # endif
 //--------------
 extern  int DC395x_proc_info(char*, char**, off_t, int, int, int);
 //--------------
 # if LINUX_VERSION_CODE >= KERNEL_VERSION(2,3,30)
 #  define DC395x_TRMS1040  {                                    \
                 proc_name:      "dc395x_trm",                   \
                 proc_info:      DC395x_proc_info,               \
                 name:           DC395x_BANNER " V" DC395x_VERSION,\
                 detect:         DC395x_detect,                  \
                 release:        DC395x_release,                 \
                 queuecommand:   DC395x_queue_command,           \
                 bios_param:     DC395x_bios_param,              \
                 can_queue:      DC395x_MAX_CAN_QUEUE,           \
                 this_id:        7,                              \
                 sg_tablesize:   DC395x_MAX_SG_TABLESIZE,        \
                 cmd_per_lun:    DC395x_MAX_CMD_PER_LUN,         \
                 EH_FUNC                                         \
                 unchecked_isa_dma: 0,                           \
                 use_clustering: DISABLE_CLUSTERING              \
                 }
 # else  /* 2.3.30 */
 extern  struct proc_dir_entry DC395x_proc_scsi;
 #  define DC395x_TRMS1040  {                                    \
                 proc_dir:       &DC395x_proc_scsi,              \
                 proc_info:      DC395x_proc_info,               \
                 name:           DC395x_BANNER " V" DC395x_VERSION,\
                 detect:         DC395x_detect,                  \
                 release:        DC395x_release,                 \
                 queuecommand:   DC395x_queue_command,           \
                 bios_param:     DC395x_bios_param,              \
                 can_queue:      DC395x_MAX_CAN_QUEUE,           \
                 this_id:        7,                              \
                 sg_tablesize:   DC395x_MAX_SG_TABLESIZE,        \
                 cmd_per_lun:    DC395x_MAX_CMD_PER_LUN,         \
                 EH_FUNC                                         \
                 unchecked_isa_dma: 0,                           \
                 use_clustering: DISABLE_CLUSTERING              \
                 }
 # endif /* 2,3,30 */
 #endif /* defined(HOSTS_C) || defined(MODULE) || LINUX_VERSION_CODE > 2,3,99 *
 /
 #endif /* DC395x_trm_H */
 
 >=====  End cut  [/tmp/1/dc395x_trm.h] =====<
 --
     Svyatoslav <absolute_sh@mail.ru>
 
 [Registered Linux user #219421]
 --- QDed/Linux
  * Origin: AbSolute Soft&Hard (2:464/8088.100)
 
 

Вернуться к списку тем, сортированных по: возрастание даты  уменьшение даты  тема  автор 

 Тема:    Автор:    Дата:  
 ASP90+2.6.5   Svyatoslav Abramenkov   21 Jul 2004 11:25:38 
 ASP90+2.6.5   Vladislav Bondarenko   22 Jul 2004 08:07:54 
Архивное /ru.linux/459000fe3750.html, оценка 1 из 5, голосов 10
Яндекс.Метрика
Valid HTML 4.01 Transitional