Deleted Added
full compact
asloperands.c (193529) asloperands.c (199337)
1
2/******************************************************************************
3 *
4 * Module Name: asloperands - AML operand processing
5 *
6 *****************************************************************************/
7
8/******************************************************************************

--- 774 unchanged lines hidden (view full) ---

783 }
784 }
785
786 /* If package length is a constant, compare to the initializer list */
787
788 if ((PackageLengthOp->Asl.ParseOpcode == PARSEOP_INTEGER) ||
789 (PackageLengthOp->Asl.ParseOpcode == PARSEOP_QWORDCONST))
790 {
1
2/******************************************************************************
3 *
4 * Module Name: asloperands - AML operand processing
5 *
6 *****************************************************************************/
7
8/******************************************************************************

--- 774 unchanged lines hidden (view full) ---

783 }
784 }
785
786 /* If package length is a constant, compare to the initializer list */
787
788 if ((PackageLengthOp->Asl.ParseOpcode == PARSEOP_INTEGER) ||
789 (PackageLengthOp->Asl.ParseOpcode == PARSEOP_QWORDCONST))
790 {
791 if (PackageLengthOp->Asl.Value.Integer >= PackageLength)
791 if (PackageLengthOp->Asl.Value.Integer > PackageLength)
792 {
792 {
793 /* Allow package to be longer than the initializer list */
793 /*
794 * Allow package length to be longer than the initializer
795 * list -- but if the length of initializer list is nonzero,
796 * issue a message since this is probably a coding error,
797 * even though technically legal.
798 */
799 if (PackageLength > 0)
800 {
801 AslError (ASL_REMARK, ASL_MSG_LIST_LENGTH_SHORT,
802 PackageLengthOp, NULL);
803 }
794
795 PackageLength = (UINT32) PackageLengthOp->Asl.Value.Integer;
796 }
804
805 PackageLength = (UINT32) PackageLengthOp->Asl.Value.Integer;
806 }
797 else
807 else if (PackageLengthOp->Asl.Value.Integer < PackageLength)
798 {
799 /*
808 {
809 /*
800 * Initializer list is longer than the package length. This
801 * is an error as per the ACPI spec.
810 * The package length is smaller than the length of the
811 * initializer list. This is an error as per the ACPI spec.
802 */
812 */
803 AslError (ASL_ERROR, ASL_MSG_LIST_LENGTH,
804 PackageLengthOp->Asl.Next, NULL);
813 AslError (ASL_ERROR, ASL_MSG_LIST_LENGTH_LONG,
814 PackageLengthOp, NULL);
805 }
806 }
807
808 if (PackageLengthOp->Asl.ParseOpcode == PARSEOP_DEFAULT_ARG)
809 {
810 /*
811 * This is the case if the PackageLength was left empty - Package()
812 * The package length becomes the length of the initializer list

--- 430 unchanged lines hidden ---
815 }
816 }
817
818 if (PackageLengthOp->Asl.ParseOpcode == PARSEOP_DEFAULT_ARG)
819 {
820 /*
821 * This is the case if the PackageLength was left empty - Package()
822 * The package length becomes the length of the initializer list

--- 430 unchanged lines hidden ---