Changeset 28055
- Timestamp:
- May 20, 2010, 4:37:23 PM (16 years ago)
- Location:
- trunk/ippTools/src
- Files:
-
- 3 edited
-
chiptool.c (modified) (1 diff)
-
pxtools.c (modified) (1 diff)
-
warptool.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/chiptool.c
r28043 r28055 1430 1430 1431 1431 // Set chipRun.software_ver to the appropriate value 1432 if (!pxSetRunSoftware(config, "chipRun", "chip_id", chip_id, software_ver)) { 1433 psError(PS_ERR_UNKNOWN, false, "failed to set chipRun.software_ver for chip_id: %" PRId64, 1434 chip_id); 1435 psFree(output); 1436 if (!psDBRollback(config->dbh)) { 1437 psError(PS_ERR_UNKNOWN, false, "database error"); 1432 if (software_ver) { 1433 if (!pxSetRunSoftware(config, "chipRun", "chip_id", chip_id, software_ver)) { 1434 psError(PS_ERR_UNKNOWN, false, "failed to set chipRun.software_ver for chip_id: %" PRId64, 1435 chip_id); 1436 psFree(output); 1437 if (!psDBRollback(config->dbh)) { 1438 psError(PS_ERR_UNKNOWN, false, "database error"); 1439 } 1440 return(false); 1438 1441 } 1439 return(false);1440 1442 } 1441 1443 // Set chipRun.maskfrac* to the appropriate values. 1442 if (!pxSetRunMaskfrac(config, "chipRun", "chip_id",chip_id, maskfrac_npix, maskfrac_static, 1443 maskfrac_dynamic, maskfrac_magic, maskfrac_advisory)) { 1444 psError(PS_ERR_UNKNOWN, false, "failed to set chipRun.software_ver for chip_id: %" PRId64, 1445 chip_id); 1446 psFree(output); 1447 if (!psDBRollback(config->dbh)) { 1448 psError(PS_ERR_UNKNOWN, false, "database error"); 1444 if (maskfrac_npix) { 1445 if (!pxSetRunMaskfrac(config, "chipRun", "chip_id",chip_id, maskfrac_npix, maskfrac_static, 1446 maskfrac_dynamic, maskfrac_magic, maskfrac_advisory)) { 1447 psError(PS_ERR_UNKNOWN, false, "failed to set chipRun.software_ver for chip_id: %" PRId64, 1448 chip_id); 1449 psFree(output); 1450 if (!psDBRollback(config->dbh)) { 1451 psError(PS_ERR_UNKNOWN, false, "database error"); 1452 } 1453 return(false); 1449 1454 } 1450 return(false);1451 1455 } 1452 1456 // set chipRun.state to 'stop' and update the magicked state -
trunk/ippTools/src/pxtools.c
r28043 r28055 125 125 *software_ver = pxMergeCodeVersions(*software_ver,this_version); 126 126 127 *maskfrac_static = ((*maskfrac_static * *maskfrac_npix) + (this_npix * this_static)) / (this_npix + *maskfrac_npix); 128 *maskfrac_dynamic = ((*maskfrac_dynamic * *maskfrac_npix) + (this_npix * this_dynamic)) / (this_npix + *maskfrac_npix); 129 *maskfrac_magic = ((*maskfrac_magic * *maskfrac_npix) + (this_npix * this_magic)) / (this_npix + *maskfrac_npix); 130 *maskfrac_advisory = ((*maskfrac_advisory * *maskfrac_npix) + (this_npix * this_advisory)) / (this_npix + *maskfrac_npix); 131 *maskfrac_npix += this_npix; 127 if (this_npix > 0) { 128 *maskfrac_static = ((*maskfrac_static * *maskfrac_npix) + (this_npix * this_static)) / (this_npix + *maskfrac_npix); 129 *maskfrac_dynamic = ((*maskfrac_dynamic * *maskfrac_npix) + (this_npix * this_dynamic)) / (this_npix + *maskfrac_npix); 130 *maskfrac_magic = ((*maskfrac_magic * *maskfrac_npix) + (this_npix * this_magic)) / (this_npix + *maskfrac_npix); 131 *maskfrac_advisory = ((*maskfrac_advisory * *maskfrac_npix) + (this_npix * this_advisory)) / (this_npix + *maskfrac_npix); 132 *maskfrac_npix += this_npix; 133 } 132 134 } 133 135 psFree(output); -
trunk/ippTools/src/warptool.c
r28054 r28055 1181 1181 return(false); 1182 1182 } 1183 // Set warpRun.software_ver to the appropriate value 1184 if (!pxSetRunSoftware(config, "warpRun", "warp_id", warp_id, software_ver)) { 1185 psError(PS_ERR_UNKNOWN, false, "failed to set warpRun.software_ver for warp_id: %" PRId64, 1186 warp_id); 1187 psFree(output); 1188 if (!psDBRollback(config->dbh)) { 1189 psError(PS_ERR_UNKNOWN, false, "database error"); 1183 // Set warpRun.software_ver to the appropriate value if ( 1184 if (software_ver) { 1185 if (!pxSetRunSoftware(config, "warpRun", "warp_id", warp_id, software_ver)) { 1186 psError(PS_ERR_UNKNOWN, false, "failed to set warpRun.software_ver for warp_id: %" PRId64, 1187 warp_id); 1188 psFree(output); 1189 if (!psDBRollback(config->dbh)) { 1190 psError(PS_ERR_UNKNOWN, false, "database error"); 1191 } 1192 return(false); 1190 1193 } 1191 return(false);1192 1194 } 1193 1195 // Set warpRun.maskfrac* to the appropriate values. 1194 if (!pxSetRunMaskfrac(config, "warpRun", "warp_id", warp_id, maskfrac_npix, maskfrac_static, 1195 maskfrac_dynamic, maskfrac_magic, maskfrac_advisory)) { 1196 psError(PS_ERR_UNKNOWN, false, "failed to set warpRun.software_ver for warp_id: %" PRId64, 1197 warp_id); 1198 psFree(output); 1199 if (!psDBRollback(config->dbh)) { 1200 psError(PS_ERR_UNKNOWN, false, "database error"); 1196 if (maskfrac_npix) { 1197 if (!pxSetRunMaskfrac(config, "warpRun", "warp_id", warp_id, maskfrac_npix, maskfrac_static, 1198 maskfrac_dynamic, maskfrac_magic, maskfrac_advisory)) { 1199 psError(PS_ERR_UNKNOWN, false, "failed to set warpRun.software_ver for warp_id: %" PRId64, 1200 warp_id); 1201 psFree(output); 1202 if (!psDBRollback(config->dbh)) { 1203 psError(PS_ERR_UNKNOWN, false, "database error"); 1204 } 1205 return(false); 1201 1206 } 1202 return(false); 1203 } 1207 } 1204 1208 1205 1209
Note:
See TracChangeset
for help on using the changeset viewer.
